Context: canonical Git and CI runners need incremental binary I/O with child processes. Forge tracks this as VL-PROC-01.
Current behavior: Child exposes pipe descriptors and lifecycle control; communicate_blocking takes complete input and accumulates capped output; streaming callbacks deliver lines. SystemAsync::ProcessManager also consumes complete input. ByteStream and Driver::adopt_fd provide binary foundations, but there is no high-level binary session.
Need: incremental binary stdin, independently drained stdout/stderr, finite buffering, NUL-safe transfer, and distinguishable EOF, exit, timeout, cancellation and truncation.
Proposed API: a portable Process::BinarySession facade with write_stdin, read_stdout, read_stderr, close_stdin, wait and cancellation. Operations return transferred counts or structured failures; opposite directions can progress concurrently. Reuse Child and the existing IO facilities; do not introduce a replacement executor or a System/IO dependency cycle.
Tests/gate: binary round trips larger than pipe capacity, stderr flooding, slow sinks, half-close, descendant-held pipes, cancellation races, exact cleanup. Preserve the capture/line APIs. Forge gates M06, M14 and M15 on this.
Context: canonical Git and CI runners need incremental binary I/O with child processes. Forge tracks this as VL-PROC-01.
Current behavior: Child exposes pipe descriptors and lifecycle control; communicate_blocking takes complete input and accumulates capped output; streaming callbacks deliver lines. SystemAsync::ProcessManager also consumes complete input. ByteStream and Driver::adopt_fd provide binary foundations, but there is no high-level binary session.
Need: incremental binary stdin, independently drained stdout/stderr, finite buffering, NUL-safe transfer, and distinguishable EOF, exit, timeout, cancellation and truncation.
Proposed API: a portable Process::BinarySession facade with write_stdin, read_stdout, read_stderr, close_stdin, wait and cancellation. Operations return transferred counts or structured failures; opposite directions can progress concurrently. Reuse Child and the existing IO facilities; do not introduce a replacement executor or a System/IO dependency cycle.
Tests/gate: binary round trips larger than pipe capacity, stderr flooding, slow sinks, half-close, descendant-held pipes, cancellation races, exact cleanup. Preserve the capture/line APIs. Forge gates M06, M14 and M15 on this.
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Context: canonical Git and CI runners need incremental binary I/O with child processes. Forge tracks this as VL-PROC-01.
Current behavior: Child exposes pipe descriptors and lifecycle control; communicate_blocking takes complete input and accumulates capped output; streaming callbacks deliver lines. SystemAsync::ProcessManager also consumes complete input. ByteStream and Driver::adopt_fd provide binary foundations, but there is no high-level binary session.
Need: incremental binary stdin, independently drained stdout/stderr, finite buffering, NUL-safe transfer, and distinguishable EOF, exit, timeout, cancellation and truncation.
Proposed API: a portable Process::BinarySession facade with write_stdin, read_stdout, read_stderr, close_stdin, wait and cancellation. Operations return transferred counts or structured failures; opposite directions can progress concurrently. Reuse Child and the existing IO facilities; do not introduce a replacement executor or a System/IO dependency cycle.
Tests/gate: binary round trips larger than pipe capacity, stderr flooding, slow sinks, half-close, descendant-held pipes, cancellation races, exact cleanup. Preserve the capture/line APIs. Forge gates M06, M14 and M15 on this.
Implemented on branch
issue-44-binary-session(commit540c3d9): portableProcess::BinarySessionwith incremental binary stdin, independently drained stdout/stderr, finite buffering, NUL-safe transfer, half-close, timeout/cancellation and structured failures. Merged intomain. Binary round trips over pipe capacity, stderr flooding, cancellation and cleanup tests pass under ASan/UBSan. Closing as done.