fix(guard): R-2 close-issue guard now fails closed on the #3400 landmine - #3497
Conversation
GitHub's closing-keyword parser reads "close: #N" inside "no-close: #N" -- the hyphen is a word boundary to it, the negating prefix is invisible. This guard's own CLOSE_RE had the identical blind spot: `no-close: #3090` / `no-close: #3477` both parsed as "PASS: every cited issue has a closing keyword", agreeing with GitHub's mistake instead of catching it. Measured cost: #3091 closed twice by this mechanism (2026-09-15/16, tracked as #3400 when found). #3400's own "Required" list asked for exactly this guard change (item 3) and was never implemented -- the pattern hit #3090 and #3477 a third time today via PR #3484, which carried two explicit "no-close:" lines naming them and still closed both. check_pr_closes_issue.sh now fails any body containing a hyphen-prefixed closing keyword next to a "#N" (no-close:, wont-fix:, skip-resolve:, ...), unconditionally, before any other check. The sanctioned marker becomes "keep-open: #N <reason>" -- a string neither GitHub's parser nor this guard's CLOSE_RE reads as a closing keyword. Self-test grows from 9 to 19 cases: 3 new RED rows prove the landmine is caught, including one where a body also correctly closes a different issue (the landmine still fails the whole body, since a false PASS anywhere is the failure mode being fixed). Also fixed the two live landmines this uncovered (#3488, #3494 PR bodies, both still open, edited in place to keep-open: before merge) and reopened #3090/#3477, closed a third time by PR #3484 via this exact mechanism. Closes #3400. keep-open: #3477, #3090 -- this lands the guard; GPU support itself is unstarted and stays open on 0.68.2.
|
§13.11 rung 1 — quorum shadow verdict Shadow mode: this records a verdict and merges nothing. A refusal |
|
pr-review v2.1.0 | verdict=FINDINGS | consultations: pmat=consulted cuda=not-triggered crux=not-triggered mutation=consulted agy=consulted | findings=4 (cited=0 measured=4 asserted=0) | index=58f6185 ancestor=true | agy=gemini-3.1-pro-high advisory | divergence: agreed=1 agy-only=0 primary-only=2 contradicted=0 | receipt=evidence/pr-review/3497/58f6185291351401ebd2ba126b71fef23770596c/receipt.intoto.jsonl (L1-self, unsigned pending CI)
Signature note: this receipt is committed unsigned by design (PR-REVIEW-SKILL-002 v2 §4.3, §12): the reviewing session has no access to the escrowed Findings (4 total, this PR's own diff —
None of these fire any §7 mechanical blocking class (B1–B6): mutation kill rate on the new guard logic is 5/5 = 100% (no dedicated 🤖 Generated with Claude Code |
Fixes #3400.
What was happening
GitHub's closing-keyword parser reads
close:immediately insideno-close:— the hyphen counts as a word boundary to it, so the negating prefix is
invisible.
check_pr_closes_issue.sh(the R-2 guard, wired intoci.yml)had the identical blind spot in its own
CLOSE_RE: a body line startingwith the negating marker and naming an issue still parsed as a real closing
reference, so the guard printed PASS instead of catching the danger.
Measured cost so far: an issue tracked in this repo's Qwen3.5 CPU work was
closed twice by this mechanism before #3400 was filed. #3400's own remedy
list asked for a guard change and nothing else landed on it. Today the same
class of line, on PR #3484, closed both the GPU sub-ticket and its parent
epic a third time — despite the body explicitly carrying the negating marker
for each.
What changed
scripts/check_pr_closes_issue.sh:NOCLOSE_LANDMINE_RE: any hyphen-prefixed closing keyword (fix,close,resolve, and their variants) immediately followed by a colon andan issue reference. Checked first, unconditionally — a landmine anywhere in
the body fails the whole check, even alongside an otherwise-correct closing
line elsewhere.
keep-open:instead of the negating marker — a string neither GitHub's parser nor this
guard's own
CLOSE_REreads as a closing keyword.including a mixed body that also correctly closes a different issue (the
landmine still fails the whole body).
Also fixed by hand (not in this diff)
Two open PRs (#3488, #3494) still carried the negating-marker line naming the
epic; edited their bodies in place to the new marker before they could merge
and reopen the same hole. The epic and the GPU sub-ticket, closed again
today by this mechanism, are reopened.
keep-open: #3477, #3090 — this PR lands the guard only; GPU device support
itself is unstarted, separate work, and stays open on milestone 0.68.2.
🤖 Generated with Claude Code