| ... | @@ -129,7 +129,14 @@ it.layer(NodeServices.layer)("Claude capability probe SDK boundary", (it) => { | ... | @@ -129,7 +129,14 @@ it.layer(NodeServices.layer)("Claude capability probe SDK boundary", (it) => { |
| 129 | " });", | 129 | " });", |
| 130 | " }", | 130 | " }", |
| 131 | "});", | 131 | "});", |
| 132 | "setInterval(() => {}, 1_000);", | 132 | "// Stay alive for follow-up control requests, but never outlive the", |
| | 133 | "// parent: the probe aborts the SDK without awaiting the child, so an", |
| | 134 | "// unconditional interval would strand this process until reboot.", |
| | 135 | "const keepAlive = setInterval(() => {}, 1_000);", |
| | 136 | 'lines.on("close", () => {', |
| | 137 | " clearInterval(keepAlive);", |
| | 138 | " process.exit(0);", |
| | 139 | "});", |
| 133 | "", | 140 | "", |
| 134 | ].join("\n"), | 141 | ].join("\n"), |
| 135 | ); | 142 | ); |