Skip to content

Commit cea8c7d

Browse files
claude[bot]claude
andauthored
fix(pm): discover gates invoked with --self-test, whose scripts carry no check- prefix (#11554)
* fix(pm): discover gates invoked as `node scripts/<x>.mjs --self-test` `collectInvocations` recognised exactly two spellings — a `check:*` npm script and a script whose basename carries `check-`. A gate following neither was not a family at all: absent from the matched list, the convention list, the unreachable list, and from all three residue buckets, because it never entered the universe those partition. `node scripts/pm/bare-root-worklist.mjs --self-test` shipped a red on the required lane for a diff whose seven derived families were all run and all green, and no local derivation could have named it. The third matcher keys on the flag rather than on a name: `--self-test` is the script's own declaration that this invocation verifies the script instead of doing its work. Two scripts in this tree are invoked BOTH ways, which no filename rule can separate. A `check-` basename is skipped here so an existing family is never split into two keys. A self-test family follows no import. `bare-root-worklist.mjs` statically imports `dispatch-gates.mjs`, whose module-body literals are join bases and tier globs; inheriting them handed one gate 2553 fabricated (gate, file) pairs — the same fabrication `check-dispatch-gates.mjs` exists to avoid by spawning the tool rather than importing it. Measured over 6465 tracked files: 140 -> 149 families, 52774 -> 52880 pairs (+106), zero lost, zero re-attributed. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_015ahemw8RcTgqtxrj15PEZx * test(pm): let the self-test name its failing case under ablation The matcher ablation destructured undefined and crashed, printing no case name — a self-test that dies reports "something is broken" where the value is "this exact case went red". Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_015ahemw8RcTgqtxrj15PEZx * docs(pm): correct the subtraction measurement in the matcher docblock All nine promoted scripts become gate files, not six; four were followed on the base tree over 111 import edges and all four declare zero literals, which is why the net subtraction is zero. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_015ahemw8RcTgqtxrj15PEZx --------- Co-authored-by: Claude <noreply@anthropic.com>
1 parent 3132c23 commit cea8c7d

1 file changed

Lines changed: 337 additions & 9 deletions

File tree

0 commit comments

Comments
 (0)