Skip to content

Commit 57fa18b

Browse files
Akos Kittakittaakos
Akos Kitta
authored andcommitted
fix: do not start obsolete daemon watcher process
Before arduino/arduino-cli#488, IDE2 required a way to stop the daemon process if the parent (backend) process crashed. However, this mechanism is no longer necessary as the CLI daemon process is not actually a true daemon process. Signed-off-by: Akos Kitta <[email protected]>
1 parent 2aae9e0 commit 57fa18b

File tree

2 files changed

+0
-39
lines changed

2 files changed

+0
-39
lines changed

arduino-ide-extension/src/node/arduino-daemon-impl.ts

-17
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@ import {
1010
} from '@theia/core/lib/common/disposable';
1111
import { Event, Emitter } from '@theia/core/lib/common/event';
1212
import { deepClone } from '@theia/core/lib/common/objects';
13-
import { environment } from '@theia/application-package/lib/environment';
1413
import { EnvVariablesServer } from '@theia/core/lib/common/env-variables';
1514
import { BackendApplicationContribution } from '@theia/core/lib/node/backend-application';
1615
import { ArduinoDaemon, NotificationServiceServer } from '../common/protocol';
@@ -71,22 +70,6 @@ export class ArduinoDaemonImpl
7170
const cliPath = this.getExecPath();
7271
this.onData(`Starting daemon from ${cliPath}...`);
7372
const { daemon, port } = await this.spawnDaemonProcess();
74-
// Watchdog process for terminating the daemon process when the backend app terminates.
75-
spawn(
76-
process.execPath,
77-
[
78-
join(__dirname, 'daemon-watcher.js'),
79-
String(process.pid),
80-
String(daemon.pid),
81-
],
82-
{
83-
env: environment.electron.runAsNodeEnv(),
84-
detached: true,
85-
stdio: 'ignore',
86-
windowsHide: true,
87-
}
88-
).unref();
89-
9073
this.toDispose.pushAll([
9174
Disposable.create(() => {
9275
if (daemon.pid) {

arduino-ide-extension/src/node/daemon-watcher.ts

-22
This file was deleted.

0 commit comments

Comments
 (0)