Repository navigation
review_log.t27: tests pin str_starts_with as a prefix check (Closes #7396) - #7405
Merged
Merged
Conversation
…7396) #7359 (b3617f2) turned the local str_starts_with from a substring check into a real prefix check, but all 14 tests passed with either body: every fixture line that hits a prefix rule starts with its needle. Three new test blocks answer differently under the two bodies: - a line carrying "reviewer: gh pr list" after offset 0 is OTHER, while the prefixed lines stay LISTING_ERROR_504 / LISTING_ERROR_OTHER; - the same pair for "gh pr list -R: transient failure" (OTHER vs RETRY); - direct str_starts_with asserts (needle mid-string, at start, longer than the haystack, empty needle). t27c test-report: 17 tests, 17 pass, FAIL 0, 0 vacuous. Negative control: str_starts_with body replaced by str_contains in a temp copy -> 14 pass, FAIL 3 (exactly the three new blocks). Seal re-saved. Census: tools/census/quiet.txt re-blessed. "named a path but not quiet" moved 167 -> 181, "a tracked path, present" 10 -> 12, "no path ANYWHERE in the step" 9 -> 7. `tri census explain` attributes all three to .github/workflows/auto-merge-ready-prs.yml, already on master; this commit does not move them, the pre-commit gate requires the re-bless to commit. Closes #7396 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This was referenced Oct 7, 2026
Merged
1 of 9 tasks
This was referenced Oct 7, 2026
Contributor
This was referenced Oct 7, 2026
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 #7396
Why
#7359 (b3617f2) turned the local
str_starts_withinspecs/queen/review_log.t27from a substring check into a real prefix check. That fix had nothing testing it: all 14testblocks passed with either body, because every fixture line that hits a prefix rule starts with its needle.What
Three new test blocks whose answer depends on prefix versus substring:
classify_listing_prefix_not_substring:x reviewer: gh pr list -R -> HTTP 504 ...andx reviewer: gh pr list -R -> 500 ...areOTHER; the same lines without thexprefix stayLISTING_ERROR_504andLISTING_ERROR_OTHER.classify_retry_prefix_not_substring:x gh pr list -R: transient failure ...isOTHER; the prefixed line staysRETRY.str_starts_with_is_a_prefix_check: needle in the middle (false), at the start (true), longer than the haystack (false), empty needle (true).The seal is re-saved and there is a NOW entry.
Evidence
t27c test-report --verbose specs/queen/review_log.t27: 17 tests, 17 pass, FAIL 0, 0 vacuous passes (the new blocks run 4, 2 and 4 runtime asserts).str_starts_with's body was replaced withreturn str_contains(haystack, needle);. Result: 14 pass, FAIL 3. The three failures are exactly the new blocks, and the original 14 still pass, which is the gap review_log.t27: tests cannot tell str_starts_with from contains #7396 describes. The temp copy was deleted afterwards.triandt27cwere built from origin/master e54d02d..githooks/pre-commit(tri hooks pre-commit) PASSED; lefthookown-languagepassed on both pre-commit and pre-push; L1 commit-msg PASSED.Census re-bless (not caused by this change)
The pre-commit gate refused the commit because the
quietcensus had moved since it was blessed at 31ad9df: "named a path but not quiet" went 167 -> 181, "a tracked path, present" went 10 -> 12, and "no path ANYWHERE in the step" went 9 -> 7.tri census explaintraces all three to.github/workflows/auto-merge-ready-prs.yml, which is already on master.tools/census/quiet.txtis re-blessed in this PR (tri census pin --bless) and the commit message names the moved numbers.🤖 Generated with Claude Code