Files
RingBRP/tools
slaguru666andClaude Opus 5 d03b3208e5 check-cited: the counter watching for invisible markers was itself case-blind
Fourth variant of the same defect, found by the peer session probing sideways.
Neither CITE nor ANY_CITE carried the `i` flag, and ANY_CITE required a literal
"cite:" with no space before the colon. So three plausible spellings were
invisible to the reader AND to the counter that exists to catch invisible
markers:

  <!-- Cite: first-blood cut.swing -->     OK 25, exit 0
  <!-- CITE: first-blood cut.swing -->     OK 25, exit 0
  <!-- cite : first-blood cut.swing -->    OK 25, exit 0

Each of those was verified carrying a citation printing 41 against an artifact
holding 40, and each reported OK with a count byte-identical to a clean tree.
The count check could not see them because it was looking for the same literal
the reader was. Capitalising the first word of a comment is not an exotic
mistake.

The two patterns are now deliberately asymmetric, which is the actual fix:

  CITE      tolerates case and spaces around the colon, so those spellings
            simply work when correctly placed.
  ANY_CITE  stays looser still, so a spelling neither of us anticipated is
            counted and named rather than skipped.

The reader accepts only what the format specifies; the counter recognises
anything a person might have meant as a citation; the difference is reported.
The failure text now covers misspelling as well as misplacement, since the
unread set can be either.

Matrix verified, exit codes read directly: a wrong value fails under all four
spellings including no-spaces; a right value passes under all of them, counting
26; a misplaced-and-capitalised marker fails; a marker missing its path fails;
clean tree OK 25 with no false positive.

Four iterations of this guard, four variants of one defect -- something that
exists and is never read -- and all four were found by the session that did not
write it.

npm run check: 16 guards, exit 0.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-13 10:33:17 +01:00
..
2026-08-30 21:34:37 +01:00