Harden stay_serial! executor shutdown/start cycle against orphaned workers and leftover sentinels #503
Labels
No labels
P0
P1
P2
P3
bug
create
delete
enhancement
filed-by/agent
filed-by/user
frozen
lint-rule
needs-info
needs-triage
next
plugin/cc-architect
plugin/os
plugin/os-adr
plugin/os-aidd-lint
plugin/os-backlog
plugin/os-context
plugin/os-doc-hygiene
plugin/os-sdlc
plugin/os-vault
project/cc-os
ready-for-agent
ready-for-human
recurring
review
update
waiting
wayfinder:grilling
wayfinder:map
wayfinder:map
wayfinder:research
wayfinder:task
wayfinder:task
wontfix
worklist/deviations
worklist/lint-rule
worklist/new-implement-build
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
jared/cc-os#503
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Context
plugins/os-sdlc/tests/test_helper.rb run_test_exclusively shuts down and restarts Minitest's parallel executor per serial test. In minitest-6.0.6 parallel.rb, Executor#start replaces @pool unconditionally: if shutdown raises or is interrupted, orphaned threads keep popping the shared @queue, and surplus nil sentinels pushed per shutdown cycle can kill the next pool's threads on their first pop. Observed during #502 verification: 1 fatal "No live threads left. Deadlock?" hang in 22 suite runs, main thread at parallel.rb:54 Thread#join under run_test_exclusively; no thread held the SerializedChdir Monitor, ruling out the new chdir lock.
Ticket-skeptic verdict: CREATE (root location is run_test_exclusively itself; provenance is an observed hang plus minitest source reading).
Tasks
Acceptance criteria
Origin