Commit c3ead55
pm gates: refuse a widening diff whose claim declares
* wip(pm): widening-tell gate, self-test green
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_018dxq7YqsLDMeZDZ5AzsgJX
* wip(pm): wire C5 into --pair
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_018dxq7YqsLDMeZDZ5AzsgJX
* fix(pm): a binary change to a tell surface is UNREAD, not narrow
`splitUnifiedDiff` wrote `additions: addedLines(patch).length` for every row,
and `addedLines(null)` is empty — so a BINARY change stamped a count nobody
took. `unreadFiles` skips a row that added nothing, so a binary edit to
`packages/spec/api-surface/*.json` arriving through the local path reported
`state: 'clean'`: the gate's own contract, declared and not enforced, inside
the gate.
The three states are now told apart by what the diff SAYS — a hunk gives the
count, a `Binary files`/`GIT binary patch` marker gives `null` (UNKNOWN), and
neither gives a real `0` (a mode-only change or a pure rename adds no line).
`addedNothing` interprets both input paths in one place, so a MISSING count can
never become a zero; GitHub's own `additions: 0` on a binary row is kept,
because that reading was taken by something that can see the blob.
The self-test pinned the two halves separately and never composed them, which
is why it stayed green. Seven composed cases now drive splitUnifiedDiff into
wideningRefusal.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_018dxq7YqsLDMeZDZ5AzsgJX
* fix(pm): drop the no-path-population marker the widening-tell gate cannot honour
The gate's CI command is its own --self-test, so on the marker's own second
listed cause the declaration read true. dispatch-gates' live guard refuses it
anyway the moment a family NAMES paths, and this one names 59: 9 from its module
body (the registry table, the objectui mirror glob, two repo slugs, four fixture
filenames) and 50 inherited from the two registers it imports on purpose,
SUSPECT_TIER_GLOBS and REGEN_ARTIFACTS.
Getting those out of a scanned position would mean hand-copying two registers
this file imports precisely so it can never disagree with them - the drift
check:pm-governed-prose exists to stop, and this gate's strongest property. So
the marker goes and the derivation stands. The header now records what the
derivation says, which part of it is right (packages/spec/src/**,
api-surface/**, the three registries - the surfaces this gate polices) and which
part is noise inherited from REGEN_ARTIFACTS, and why one cheap self-test in a
MATCHED column is the smaller error than a marker sitting above a live
population.
The case that catches this sits at ~1534 of dispatch-gates' self-test and needs
well over 540s to reach, which is why three local runs missed it.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_018dxq7YqsLDMeZDZ5AzsgJX
---------
Co-authored-by: Claude <noreply@anthropic.com>Clause-②: no (the mechanical half of the directional ruling) (#16604)1 parent bc0ac1d commit c3ead55
4 files changed
Lines changed: 1391 additions & 17 deletions
File tree
- .github/workflows
- scripts/pm
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
975 | 975 | | |
976 | 976 | | |
977 | 977 | | |
| 978 | + | |
| 979 | + | |
| 980 | + | |
| 981 | + | |
| 982 | + | |
| 983 | + | |
| 984 | + | |
| 985 | + | |
| 986 | + | |
| 987 | + | |
| 988 | + | |
| 989 | + | |
| 990 | + | |
978 | 991 | | |
979 | 992 | | |
980 | 993 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
75 | 75 | | |
76 | 76 | | |
77 | 77 | | |
| 78 | + | |
78 | 79 | | |
79 | 80 | | |
80 | 81 | | |
| |||
0 commit comments