R-422: reuse_refs_check checks .md citations too
PATH_RE gains .md. The false-positive walk across all four repos found one: an audit document cited by app-catalog's REUSE.md, hidden by the evidence-copy exclusion — excluded trees are now walked for .md documents only, so a .go evidence copy there still never satisfies a citation. The KNOWN HOLE decoy now expects a conviction. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_0159rPz1ZhFKsS53msqPYxtS
This commit is contained in:
@@ -42,7 +42,7 @@ COVERS = {
|
||||
"hub-confirm": "a native confirm() in templates/partials/ (scope was os.listdir)",
|
||||
"manifest-bearer": "a bearer literal in manifests/overlays/ (scope was os.listdir)",
|
||||
"observations": "R-419: prose SAYING it carries no marker, plus both genuine markers",
|
||||
"reuse-refs": "a cited .go path that does not exist; the .md hole is asserted as R-422",
|
||||
"reuse-refs": "a cited .go path, and (R-422) a cited .md path, that does not exist",
|
||||
"golden-currency": "R-410: an empty directory with a perfect name, checked by what it COUNTED",
|
||||
"closed-register": ("a verdict cell reading open, a row with no state cell at all, and (RULE 3, "
|
||||
"2026-10-03) a FINISHED row left in OPEN-ITEMS.md — with R-87's shape, a READY "
|
||||
@@ -165,20 +165,17 @@ decoy("observations/genuine-NAF", "observations_gate.py",
|
||||
u"typo, corrected in the same minute.**\n"), args=(ROOT,), expect="accept")
|
||||
|
||||
# --- reuse-refs: a cited path that does not exist ----------------------------------------------
|
||||
# The .go case is REJECTED. The .md case is a KNOWN HOLE (R-422) and is asserted as such below, so
|
||||
# this file records the hole rather than pretending it is covered.
|
||||
# Both the .go and (since R-422, 2026-10-05) the .md case are REJECTED.
|
||||
decoy("reuse-refs/missing-go", "reuse_refs_check.py",
|
||||
append_to(os.path.join(ROOT, "REUSE.md"),
|
||||
u"\n- see `hub/internal/api/does_not_exist.go`\n"), args=(ROOT,))
|
||||
|
||||
# --- KNOWN HOLE, asserted so it cannot be forgotten (R-422) ------------------------------------
|
||||
# reuse_refs_check.py's PATH_RE matches only go|py|html|css|yml|yaml|sh. A rotted .md citation is
|
||||
# invisible. This asserts the CURRENT behaviour so the day it is fixed, this test fails and is
|
||||
# updated deliberately — a hole that nothing asserts is a hole nobody remembers.
|
||||
decoy("reuse-refs/missing-md (KNOWN HOLE R-422)", "reuse_refs_check.py",
|
||||
# R-422 CLOSED THE HOLE this decoy used to assert (expect="accept"): PATH_RE now includes .md, so a
|
||||
# rotted document citation is convicted. Updated deliberately, as the old comment asked.
|
||||
decoy("reuse-refs/missing-md (R-422)", "reuse_refs_check.py",
|
||||
append_to(os.path.join(ROOT, "REUSE.md"),
|
||||
u"\n- see `documentation/architecture/99-does-not-exist.md`\n"),
|
||||
args=(ROOT,), expect="accept")
|
||||
args=(ROOT,))
|
||||
|
||||
# --- golden-currency: R-410's own decoy, re-run here so the sweep owns it too ------------------
|
||||
def _mkdir_decoy():
|
||||
|
||||
Reference in New Issue
Block a user