Skip to content

Commit d82ca53

Browse files
committed
pm-dispatch(mailbox): declare the recogniser's governed self-test read and register it in the dispatch-gates census
The doorbell battery reads project-forms.md to pin the seven key templates verbatim — a population claim on a governed file. check:pm-dispatch-gates reds a new governed read until it is classified: the read is declared (self-test-reads marker in record-recognisers.mjs), GOVERNED_READ_FLOOR carries its row (declared: true) and the live-declaration roster of the self-test gains its ninth line. Measured: a change set holding project-forms.md alone now derives pnpm check:pm-record-recognisers, keyed on the declaration. Co-authored-by: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01QSeKYmhU5KEj1nukYhp1Tg
1 parent 2a864ee commit d82ca53

3 files changed

Lines changed: 28 additions & 2 deletions

File tree

‎scripts/pm/dispatch-gates.data.mjs‎

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -499,6 +499,15 @@ export const COMPOUND_ANCHOR_LEDGER = [
499499
* the governed file is its input, not a fixture; it spells that path in its
500500
* module body and is MATCHED for it the same way the two undeclared rows
501501
* above are, so `declared` is false for the same reason.
502+
*
503+
* ## The fifth row: the mailbox doorbell's spelling pin
504+
*
505+
* `scripts/pm/record-recognisers.mjs` reads the seven doorbell keys off the
506+
* pm-dispatch references' `project-forms.md` in its self-test, to pin each
507+
* key's template verbatim in the protocol text — a population claim on a file
508+
* a card can edit, the `check-expected-skips` shape exactly. It is DECLARED
509+
* (`self-test-reads`), so a card touching that file derives
510+
* `check:pm-record-recognisers`.
502511
*/
503512
export const GOVERNED_READ_FLOOR = Object.freeze([
504513
Object.freeze({ script: 'scripts/check-commit-card-trailers.mjs', file: '.claude/agents/os-dev.md', declared: false }),
@@ -517,6 +526,11 @@ export const GOVERNED_READ_FLOOR = Object.freeze([
517526
file: '.claude/settings.json',
518527
declared: false,
519528
}),
529+
Object.freeze({
530+
script: 'scripts/pm/record-recognisers.mjs',
531+
file: '.claude/skills/pm-dispatch/references/project-forms.md',
532+
declared: true,
533+
}),
520534
]);
521535

522536
/**

‎scripts/pm/dispatch-gates.self-test.mjs‎

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7535,7 +7535,7 @@ export function selfTest({ tier = 'full' } = {}) {
75357535
}
75367536
const censusRows = liveMarkerCensus.map((r) => `${r.file}:${r.line} ${r.key}`).sort();
75377537
t(
7538-
`the live tree carries the eight declarations measured for this census, and no others (${censusRows.join(' · ') || 'none'})`,
7538+
`the live tree carries the nine declarations measured for this census, and no others (${censusRows.join(' · ') || 'none'})`,
75397539
censusRows.join(' · ') === [
75407540
// Seventh row, added with the declaration it names: `checklist-status.yml`
75417541
// is paths-filtered (its `pull_request:` trigger is filtered to itself) and
@@ -7557,13 +7557,18 @@ export function selfTest({ tier = 'full' } = {}) {
75577557
'scripts/pm/check-expected-skips.mjs:137 self-test-reads',
75587558
// 736 -> 738 (#26318): the data import and its re-export each gained UI_SCRIPTS_SUITE_ROOTS.
75597559
'scripts/pm/dispatch-gates.mjs:738 inherited-population',
7560+
// Ninth row, added with the declaration it names: the recogniser's mailbox
7561+
// doorbell battery pins the seven key templates verbatim in the pm-dispatch
7562+
// references' project-forms.md, a population claim on a governed file, so
7563+
// that read is declared and `GOVERNED_READ_FLOOR` carries its row.
7564+
'scripts/pm/record-recognisers.mjs:77 self-test-reads',
75607565
].join(' · '),
75617566
censusRows.join(' · '),
75627567
);
75637568
const censusCut = liveMarkerCensus.filter((r) => !r.whole).map((r) => `${r.file}:${r.line} ${r.key}`);
75647569
t(
75657570
`every live reason on those markers ENDS on its own marker line (cut: ${censusCut.join(', ') || 'none'})`,
7566-
censusCut.length === 0 && liveMarkerCensus.length === 8,
7571+
censusCut.length === 0 && liveMarkerCensus.length === 9,
75677572
);
75687573
t(
75697574
'and every one of them carries a non-empty reason — whole is not the same claim as present, and both are owed',

‎scripts/pm/record-recognisers.mjs‎

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,13 @@
6969
* which exit — is the guard's.
7070
*/
7171

72+
// The self-test's one read of a GOVERNED file, declared so a card editing that
73+
// file derives this family (`dispatch-gates.mjs` `declaredSelfTestReads`; the
74+
// row is `GOVERNED_READ_FLOOR` in `dispatch-gates.data.mjs`). The derivation
75+
// grades it against the read the self-test really performs, so it cannot be
76+
// satisfied by deleting either half.
77+
// dispatch-gates: self-test-reads .claude/skills/pm-dispatch/references/project-forms.md -- the mailbox doorbell battery pins each of the seven key templates verbatim in that file's 〈信箱 PR〉 section, so a change to the keys' spelling there is judged here
78+
7279
import process from 'node:process';
7380
import { spawnSync } from 'node:child_process';
7481
import { readFileSync } from 'node:fs';

0 commit comments

Comments
 (0)