Skip to content

capture pays DRAIN_GRACE once per pipe, so the drain bound is 1.0s not 0.5s #501

Description

@blooop

Residue from verifying #355 (found 2026-08-29, on main).

capture drains stdout then stderr serially (rust/devlaunch-runner/src/lib.rs:497-498, collect(stdout) then collect(stderr)), and each collect gets its own DRAIN_GRACE. Two held pipes therefore cost up to 1.0s, where a reader of the timeout design could take the grace as a single bound on the drain.

The DRAIN_GRACE doc comment is accurate as written: it says how long collect gives a drained pipe to reach EOF, which is per-pipe and true. So this is a behaviour question, not a wrong comment: should the two drains share one deadline?

Context: the drain bounds landed in PR #343 (#301/#302); the EINTR half of the review residue was #355, closed as already fixed by #343.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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