Repository navigation
test(harness): the known-red, no-oracle and failed-run-leftover ceilings are counted from the tree, not typed - #841
Merged
Conversation
added 3 commits
November 4, 2026 21:48
…ngs are counted from the tree, not typed Why: ENTRY_CEILING, NO_ORACLE_CEILING and FAILED_RUN_LEFTOVER_CEILING were hand-typed copies of a count the ledger or the live tests already hold. Every product PR that moved one rewrote the same line (and appended to the same history comment), so the merge queue serialised them. What: - pr_ready.py: a `ratchet-pin: NAME count <pathspec> <regex>` pin is measured by git grep at the base and at the head; a regex that matches nothing, or does not compile, is an error, never a shrink. `pr_ready.py pins` prints every pin. - known_red_guard.rs: ENTRY_CEILING and its assert_eq are gone; the pin counts the ledger's entry lines, a test compares that census with the ledger's own length, and known_red.py refuses an entry whose reason carries no ISO date. - rig_oracle_ratchet.rs: NO_ORACLE_CEILING and FAILED_RUN_LEFTOVER_CEILING and their two assert_eq tests are gone; the same pins are counted. - Shrink-only is unchanged: a rise of a pin over the merge base still needs `Ratchets raised` in the PR body (pr-rules).
…-ledger-pr # Conflicts: # tests/offline/known_red_guard.rs
20 tasks
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.
Why
The three hand-typed ceilings (ENTRY_CEILING, NO_ORACLE_CEILING, FAILED_RUN_LEFTOVER_CEILING) drifted from the tree and had to be bumped by hand on every PR that touched a ledger. The count should come from the tree, and a census that matches nothing should fail loudly instead of passing as zero.
What
dev/pytools/pr_ready.py: the three typed ceilings becomecount <pathspec> <ERE>pins. A zero-match census is an error ("census is blind").dev/release_oracle/known_red.py: every known-red entry must carry an ISO date in its reason.tests/offline/known_red_guard.rs,tests/offline/rig_oracle_ratchet.rs: the guards read the counted pins; no hand-kept number.CONTRIBUTING.md: the pin mechanism is documented.src/change.Pin values on this branch equal origin/main: known-red-entries 31, no-oracle-opt-outs 32, failed-run-leftover-declarations 53.
Ratchets raised: none
Open PRs #816, #814, #801 carry ENTRY_CEILING and NO_ORACLE_CEILING lines that this PR replaces. After this merges and they merge main, those lines must be removed from their branches (see #816, #814, #801).
Evidence
cargo test --test offline_suitetest result: ok. 476 passed; 0 failed(before merge main)cargo clippy --all-targets -- -D warningscargo clippy --all-targets --no-default-features --features jemalloc -- -D warningspython3 dev/pytools/pr_ready.py pinspython3 -m dev.release_oracle.known_redknown_red: 31 entries, every reason datedgit diff origin/main -- src/git pushSummary 1194 tests run: 1194 passedNot verified: mutants (
cargo mutants --in-diff), live cells, CI on the PR head.Not run by this PR: merge, enqueue.
🤖 Generated with Claude Code
https://claude.ai/code/session_01C3FJRFo5EtJ4cb9uWKcr2w