Repository navigation
fix(test): make claim-test stub CAS independent of mkdir - #481
Merged
Merged
Conversation
Ubuntu 26.04 runners ship uutils mkdir 0.8.0, which checks for the leaf and then creates it, so two racing creates both succeeded and the simultaneous-claims rounds failed with exits 0:0. The stub gh now claims a label with bash's noclobber redirect, an O_EXCL open of its description file, and a racy mkdir shim on the test PATH makes any regression to a mkdir CAS fail on every host. Closes #480
Owner
Author
Review — PR #481 (issue #480)
|
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 #480.
What this changes
tests/fixtures/quest-log/claim-test.sh's stubghusedmkdir <leaf>as its label-create compare-and-swap. Theubuntu-latestrunner image moved from Ubuntu 24.04 to 26.04, where/usr/bin/mkdiris uutils coreutils 0.8.0. Thatmkdirchecks for the leaf and then creates it, so two racing calls both succeed, and the simultaneous-claims rounds failed withexits 0:0.Reproduction in containers, two
mkdircalls racing on one leaf, 2000 trials:mkdir --versionThe issue's kernel-
mkdir(2)hypothesis does not hold, and pre-creating the parent would not have fixed it.set -C), which opens the description file withO_CREAT|O_EXCL. That open is a shell builtin, so no coreutils implementation decides the race.mkdirshim on the suite's PATH (check, sleep 0.2 s, create;-ppasses straight through) makes a regression to amkdir-based CAS fail the simultaneous-claims rounds on every host, macOS included..claude-plugin/plugin.json7.12.3 → 7.12.4.Production
tracker.sh/profiles/github.share unchanged; they call the GitHub API and nevermkdir.Verification
claim-test: round 1: exits 0:0, expected one 0 and one 6.just cipassed via the pre-push hook on915ae4b.Review
Single-pass adversarial review (routed: no change hazards, size S, one PR, not security-relevant; security pass not triggered) returned
approvewith three notes:mkdir -pstill makes the directory): accepted, comment narrowed. The suggested|| [[ -d ]]guard was rejected: concurrentmkdir -ptolerates an existing directory, and uutils passed 5/5 container runs.Deferrals: none.