fix(port): check-citations was red, and its selftest BROKEN, on a clean tree #66
Reference in New Issue
Block a user
Delete Branch "fix/citations-generated-tree"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Same shape as #65, found the same way — by running the gates on
maininstead of assuming they were green. Two independent defects, both reporting a correct checkout as wrong. Neither is new; both were invisible because nobody ran this here.1. A citation of generated output is not a dangling citation
export/is the exporter's output and is gitignored (.gitignore→/export*/). A checkout where nobody has run the exporter has noexport/at all, so four citations landed in resolve NOWHERE and the check exited 1:Red for a state no edit can fix — the exact shape its own docstring says it exists to avoid.
check-capture-citationsalready learned this fordocs/re/captures/, so the rule is borrowed rather than invented: absent because unbuilt is reported; absent while the tree IS built still fails.Verified both directions —
mkdir exportand the same four go straight back to failing (exit 1). The leniency is scoped to "the tree was never built", not toexport/as a prefix.2. The selftest was asserting against a file that became ordinary
Its peer-branch fixture cited
docs/re/f5-a-press-snaps-the-plate.md— which the consolidation made an ordinary local file. The fixture stopped testing the scanner and started reporting it broken.PEER_REFSalso still namedorigin/auto/frame-blend-draw-path, a branch that no longer exists.So
--selftestprints 🔴 BROKEN onmaintoday, for itself, not for the code under test.It now finds a peer-only path at runtime; where none exists — the normal case on a clean checkout, measured: zero — it says the class is empty here rather than claiming a failure. The class itself stays: the next topic branch that lands a finding recreates the condition exactly.
Measured
check-citationsexit--selftestThe new generated-tree selftest case was confirmed to FAIL against the unfixed function before the fix went in.
What to look at
Pass:
tools/port/check-citationsexits 0 and lists the four under not built in this checkout;--selftestends-> ok.Fail: either still reports
resolve NOWHERE, ormkdir export && tools/port/check-citationsexits 0 — that would mean the leniency is too wide.Not in scope
tools/port/check-all,check-claimsandcheck-moddingcd /workand only run inside the container;contract-checkneeds an export.audit-kindsexits 1 on 9 danglingkindcitations inauthored/— that is port content, not a tooling defect, and belongs to whoever picks up the F-series work.🤖 Generated with Claude Code