Repository navigation
fix(driver): terminate the whole process tree on timeout or cancel - #11
Merged
Merged
Conversation
…ls-process-group # Conflicts: # CHANGELOG.md
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
A timed-out call killed only the direct child. Anything the CLI had spawned kept running and held the pipes.
fan_outsends SIGTERM to the whole process group, waitsAGENT_TERM_GRACE_S(default 5 seconds), then sends SIGKILL to what is left.AgentErrorkeeps the partial output on.stdoutand.stderr, and quotes a tail in the message.Plan unit: CBR-2 (portfolio remediation 2026-09-29).
Limits, stated in the docs
Design decisions to review
fan_outstops every tree this module is running, including one from a concurrentfan_outin another thread.subprocess.runtodriver._run_bounded. Existing assertions are unchanged. Only the patch target and the fake's signature changed.Test plan
fan_outinterrupt kills every live tree, normal completion unchanged. Three were red before the change ("grandchild survived the timeout").Merge order
This PR and the frame-id PR both add a line under Unreleased in CHANGELOG.md. Whichever merges second needs a one-line conflict fix there.