Skip to content

design-bindings:note-witness: a cited file path must exist (X-1207); PB-58 re-cited - #1013

Merged
MattJackson merged 1 commit into
predevfrom
lane-proof-note-witness-paths
Oct 15, 2026
Merged

MattJackson merged 1 commit into
predevfrom
lane-proof-note-witness-paths

Conversation

@MattJackson

Copy link
Copy Markdown
Collaborator

TODO l.3669 X-1207: note_witness_offenders (xtask/src/gates/design_bindings/verify.rs:643) checked test-shaped identifiers only. A note citing a file that no longer exists read as evidence. PB-58 cited crates/busbar-caps/src/decision.rs, a file that went away when busbar-caps was folded.

  • cited_paths reads every repository path a note cites (globs excluded). The rule now refuses a path that is not on disk.
  • PB-58 now cites crates/busbar-contract/src/caps/seat_verdict.rs, where the three reason codes live. qa/design-bindings.json and qa/DESIGN-BINDINGS.md are updated in step.
  • RED: a selftest plant of a note citing a missing path, over the green baseline. Control: a path on disk is accepted. A unit test covers the reader.

DRAFT until #830 lands (coordinator: X-1207 follows #830). The hunks are disjoint: #830 edits verify.rs l.256 and l.403, this PR edits l.633+.

…k (X-1207)

TODO l.3669 X-1207: note_witness_offenders tested identifier-shaped tokens (>= 8 chars, >= 3
underscores) against the tree's symbols only, so a note citing a FILE PATH that is gone read as
evidence -- and the note that motivated the rule carried one: PB-58 cited
crates/busbar-caps/src/decision.rs, a file folded away with busbar-caps.

verify.rs: cited_paths reads every path a note cites (a run of path characters from a repository
root -- crates/, xtask/, scripts/, qa/, docs/, testing/, conformance/, .ci/, .github/ -- with a :line
suffix and sentence punctuation dropped; a run touching `{` or `*` is a pattern, not a citation),
and note_witness_offenders refuses one that is not on disk.

PB-58 now cites crates/busbar-contract/src/caps/seat_verdict.rs, where OverBudget,
OverdraftCeiling and StaleSlice are declared; qa/design-bindings.json and qa/DESIGN-BINDINGS.md carry
the same note text.

RED: selftest "a note citing a file path that is not on disk is refused (X-1207)" over the green
baseline; control: a note citing a path on disk is accepted; unit test for the path reader.
@MattJackson
MattJackson merged commit 130bccc into predev Oct 15, 2026
1 check was pending
@MattJackson
MattJackson deleted the lane-proof-note-witness-paths branch October 15, 2026 13:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant