You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
check-contract-slice-prune.test.sh is flaky in CI: fixture cleanup race fails contract-slice-prune-gate #2918
scripts/check-contract-slice-prune.test.sh intermittently fails the contract-slice-prune-gate job on pull requests that do not touch the code under test.
Failing case: carrying existing debt to a new root must not be red-lined
Log line: rm: cannot remove … Directory not empty
The same test passed 33 of 33 consecutive local runs at the same commit
A CI re-run went green with no change
Why it matters
This is the expensive kind of flake. It turns a green branch red for reasons unrelated to its diff, and it teaches everyone who sees it to re-run rather than read the failure — which is how a real failure eventually gets re-run past.
A fixture-cleanup race. Candidates worth checking, in rough order of likelihood:
A trap-based cleanup firing while a background process still holds a handle under the fixture directory.
A fixture path not unique per case, so two cases collide when timing shifts.
A rm -rf racing a subshell that is still writing.
CI is ubuntu-24.04 with git 2.54.0, so the mechanism that matters for the gate is a Linux one. Reproducing it may need a loop, concurrent case execution, or a contended filesystem — a container matching the CI image is the most direct route, since the failure has not been reproduced on Windows.
Definition of done
Root cause identified and fixed, plus a deterministic regression case. A stress loop is acceptable supporting evidence but is not a substitute for a test that fails before the fix and passes after.
If the race cannot be reproduced, that should be stated openly rather than papered over with a speculative fix — a flake fixed by guessing is a flake moved, not removed.
Activity
fix(scripts): stop fixture git commands spawning background maintenan…
fix(scripts): give the maintenance-child guard a positive control (#2993
refactor(scripts): dissolve incident history in gate headers (group 5)