Repository navigation
fix(core): keep a zombie with live threads in the verified group stop - #323
Merged
Merged
Conversation
stopProcessGroupVerified treated a zombie group leader as gone even while its other threads still ran or exited. Read num_threads from /proc stat and count a zombie with more than one thread as present in the group-gone and after-SIGTERM checks. Identity checks keep treating every zombie as dead. Refs #320
3 tasks done
2 tasks done
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.
Closes #320
A verified group stop no longer returns while a zombie leader or member still has live threads.
parseProcStatnow readsnum_threads. The stop path counts a process as present when it is not a zombie, or when it is a zombie with more than one thread. Identity and ownership checks still treat every zombie as dead, so PID-reuse rules do not change. Session teardown (stopXvfb), the desktop session stops, Xvfb startup rollback and the Chrome group stop all callstopProcessGroupVerifieddirectly, so this core change covers them.num_threads > 1counts as present only in the stop path;processIdentityMatchesandlistProcessGroupMembersstill treat it as gonepackages/core/test/proc.test.tscoverage-320.logstopProcessGroupVerifiedwithout an identity pre-checkPICKFORGE_REQUIRE_BROWSER=1coveragecoverage-320.log--base origin/main --fail-on new,worsened,unmatchedpickcheck-320.jsonEvidence is in
~/Artifacts/pickforge-batch6-2026-10-09/on the build host.No device pass: this is an internal process-stop rule with nothing to drive, and the tests cover it.
Follow-ups: #322 (containment probes treat a zombie with live threads as gone), #324 (stop reports a group gone when /proc stat is unreadable), #327 (viewer Chrome stop keeps the old zombie rule).