PR #344 needed to settle a command on its exit rather than on the close of its stdio pipes: Process.join()/expect() resolve only after exit AND pipe EOF, so a pipe fd inherited by a straggling grandchild (or slow stream delivery) defers the result indefinitely even though the command finished — which a fixed deadline then converts into a timeout that discards produced output (#343).
The package exposes no way to observe the child's exit: Process carries only pid, the stdio streams (EOF-settled), and close-settled join/expect. The default Process handler in packages/runtime/apis.ts therefore spawns via node:child_process directly, duplicating the detached-process-group discipline @effectionx/process already implements.
If upstream ever grows an exit-settled primitive (e.g. Process.exited(): Operation<ExitStatus> or a join({settle: "exit"}) option), execSettledOnExit should collapse back onto it. Until then this issue records why the runtime bypasses the package for exec.
PR #344 needed to settle a command on its exit rather than on the close of its stdio pipes:
Process.join()/expect()resolve only after exit AND pipe EOF, so a pipe fd inherited by a straggling grandchild (or slow stream delivery) defers the result indefinitely even though the command finished — which a fixed deadline then converts into a timeout that discards produced output (#343).The package exposes no way to observe the child's exit:
Processcarries onlypid, the stdio streams (EOF-settled), and close-settledjoin/expect. The default Process handler inpackages/runtime/apis.tstherefore spawns vianode:child_processdirectly, duplicating the detached-process-group discipline@effectionx/processalready implements.If upstream ever grows an exit-settled primitive (e.g.
Process.exited(): Operation<ExitStatus>or ajoin({settle: "exit"})option),execSettledOnExitshould collapse back onto it. Until then this issue records why the runtime bypasses the package for exec.