fix(hopper): stop Linux demo children when the REA owner exits (#2499)
Bind the owned demo helper to REA's private stdin stream and unwind child cleanup on EOF during startup or analysis. Verify graceful and SIGKILL owner exit through real CLI/MCP workflows and preserve unrelated processes. Assisted-by: Reimu (gensokyo-skills:reimu-incident-triage)
This commit is contained in:
@@ -413,6 +413,8 @@ const launchHopperProcess = async (input: {
|
||||
runId: input.session.runId,
|
||||
expectedCommand: ownershipCommand,
|
||||
hostEnvironment: input.options.environment,
|
||||
// The helper observes EOF when this REA process exits, including SIGKILL.
|
||||
stdin: "pipe",
|
||||
...(input.signal === undefined ? {} : { signal: input.signal }),
|
||||
});
|
||||
return spawn(input.argumentsForTarget);
|
||||
@@ -434,6 +436,7 @@ export const linuxDemoLaunch = (
|
||||
return undefined;
|
||||
const helperArguments = [
|
||||
options.demoHelperPath,
|
||||
"--owner-stdin",
|
||||
"--strategy",
|
||||
strategy ?? "direct",
|
||||
...(strategy === "user-mount-namespace" ? ["--mount-private-x11"] : []),
|
||||
|
||||
Reference in New Issue
Block a user