Repository navigation
feat(platform): kill process groups whole - #152
Open
PiquelChips wants to merge 1 commit into
Open
PiquelChips wants to merge 1 commit into
PiquelChips wants to merge 1 commit into
Conversation
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 34 minutes. View limit details
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. |
PiquelChips
force-pushed
the
feat/ci-process-groups
branch
3 times, most recently
from
November 22, 2026 18:54
d92fa74 to
211bc1e
Compare
A command that starts others, as a test suite or a build does, leaves them running when it ends or is killed. Whatever runs checks needs to stop a command whole, and never stop a group that isn't its own. `Processes` is a new platform trait. `kill_group` kills a process group, which a command started with `process_group(0)` leads, with whatever it left running there. `inherit` lets the commands started next inherit a file, open, so a lock it holds stays held while any of their processes lives. `group_holds` tells whether a group still holds that file, so a group that ended, whose number another took since, is never killed. Linux reads the files a group holds from `/proc`. macOS can only list them through `libproc`, which needs `unsafe`, so it says no and `SEES_HELD_FILES` is false: what a command leaves running there is left running rather than risk killing someone else's.
PiquelChips
force-pushed
the
feat/ci-process-groups
branch
from
November 22, 2026 19:20
211bc1e to
7918de6
Compare
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.
A CI runner has to stop a check whole: a test suite or a build starts processes of its own, which outlive the command when it ends or is killed. It must also never stop someone else's processes.
origin-platformgets aProcessestrait:kill_groupkills a process group, which a command started withprocess_group(0)leads, with everything it left running there.inheritlets the commands started next inherit a file, open, so a lock it holds stays held while any of their processes lives.group_holdstells whether a group still holds that file, so a group that ended, whose number another group took since, is never killed.Linux reads the files a group holds from
/proc. macOS can only list them throughlibproc, which needsunsafe, so it says no (SEES_HELD_FILESis false): what a command leaves running there is leaked rather than risk killing the wrong group.The conformance suite checks that a group is killed whole, that an inherited lock is held by what holds it, and that no platform claims a group holds a file it doesn't.
Note
Written by Claude Opus 5.5 in Claude Code (via T3 Code)