Skip to content

@effectionx/process has no exit-settled join — runtime exec spawns directly #345

Description

@taras

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.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions