Skip to content

Commit a7d9764

Browse files
os-try2026claude
andcommitted
fix(qa): catch the two line-pin spellings step (1) left, and document the anchor
Measured while sweeping the ledger for anchorable citations: four line pins survived PR #13786 in two spellings its detector cannot reach — `AiChatPage .tsx:~605-615` (the tilde INSIDE the colon form; the battery only ever pinned `~:`) and `~L7246-7331`, which carries no colon at all. Both read exactly like the class step (1) removed, and both sat green through it. - the detector gains both branches, with a left AND right boundary on the `L` form so `SQL2019` / `L10n` / `L1` stay silent (six new rows, both directions); - the four citations are repaired — and repairing one surfaced what the resolver is for: `registerRecordShareEndpoints` has not been in `rest-server.ts` for some time (the record-shares routes are registered inline, under no registrar of its own), so the citation had been naming nothing while reading as verified; - README gains the anchor spelling, what is anchorable and why an unresolvable citation stays BARE, the shrink-never floor and its ⛔ MAINTAINER-ONLY authority — and the note that a red here reaches whoever runs the gate, not every PR (#11730); - the battery roster floors are set from measured counts. Refs #13788 Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01TouCuN9vQdktkP2MAEgnDC
1 parent f681a45 commit a7d9764

5 files changed

Lines changed: 57 additions & 10 deletions

File tree

‎docs/qa/platform-checklist/README.md‎

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -165,6 +165,35 @@ Why this shape:
165165
tell a rotted one from a fresh one — so it keeps reading as "verified against source"
166166
while pointing somewhere else. The file plus the symbol name is already the
167167
load-bearing half. `check:platform-checklist` fails on any that reappear.
168+
- **Write the symbol as an ANCHOR where the gate can resolve one** — the file path, a
169+
`#`, and the symbol, with the prose beside it unchanged:
170+
171+
```text
172+
packages/core/src/security/platform-admin.ts#parsePlatformAdminEmails (whole-variable refusal)
173+
```
174+
175+
`check:platform-checklist` resolves every anchor: the file must be in this repo and the
176+
symbol must still be in it, **comments masked** — a symbol surviving only in a docblock
177+
is ABSENT, because prose about a symbol is not a symbol. A symbol inside a string
178+
literal counts as present: much of what this ledger cites *is* a string (capability
179+
names, error codes, `sys_*` machine names). Dotted anchors resolve segment by segment.
180+
This is presence-in-code, not a declaration analysis — what it catches is the rename or
181+
deletion that leaves the pointer naming nothing, which is exactly the rot the line
182+
numbers used to carry.
183+
- **A citation the gate cannot resolve stays BARE — that is honest, not a gap.** Anchors
184+
are only for extensions the gate reads symbols out of (`.ts .tsx .mts .cts .js .mjs
185+
.cjs .json`); an anchor on a `.md` or a `.yml` is an ERROR rather than a silent skip,
186+
since a spelling that resolves nowhere is the false pointer all over again. Same for a
187+
sibling-repo citation (`objectui …`) and for a file with no symbol worth naming: cite
188+
the path, put the detail in prose.
189+
- **Anchors are shrink-never.** Deleting a `#symbol` is the silent way past any red the
190+
resolver prints, so the count per family file is floored in
191+
[`scripts/checklist-symbol-anchor-baseline.json`](../../../scripts/checklist-symbol-anchor-baseline.json)
192+
(authored from `node scripts/check-platform-checklist.mjs --anchor-census`, which is a
193+
census and not a verdict). Adding anchors never reds; ⛔ lowering a floor is
194+
MAINTAINER-ONLY. ⚠️ Note what a red here reaches: `check:platform-checklist` is not
195+
CI-wired (see "Operating cadence"), so it reaches whoever runs the gate — **not every
196+
PR**. #11730 holds that gap.
168197
- **`why` is the debt marker.** A recipe exists because stock fixtures cannot demonstrate
169198
something — the same discipline as a coverage waiver. Landing the fixture in the
170199
showcase seeds proper retires the recipe; until then `why` says what is missing and

‎docs/qa/platform-checklist/areas/access-security.json‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1111,7 +1111,7 @@
11111111
],
11121112
"source": [
11131113
"packages/rest/src/rest-route-ledger.ts#shareId (record-shares family: GET/POST /data/:object/:id/shares, DELETE .../:shareId; sharing-rules family evaluate)",
1114-
"packages/rest/src/rest-server.ts#registerSharingRuleEndpoints (registerRecordShareEndpoints ~L7246-7331; registerSharingRuleEndpoints evaluate ~L7477-7493)",
1114+
"packages/rest/src/rest-server.ts#registerSharingRuleEndpoints (the evaluate leg; the record-shares family GET/POST /data/:object/:id/shares + DELETE .../:shareId is registered inline, under no registrar of its own — #13788 measured that the registerRecordShareEndpoints this citation used to name is not in the file)",
11151115
"packages/plugins/plugin-sharing/src/objects/sys-record-share.object.ts#recipient_type (recipient_type/recipient_id/access_level/source fields)",
11161116
"packages/plugins/plugin-sharing/src/sharing-rule-service.ts#evaluateRule (evaluateRule → SharingRuleEvaluationResult)",
11171117
"examples/app-showcase/src/security/sharing-rules.ts#share_key_account_qualified_contacts_with_managers (share_key_account_qualified_contacts_with_managers seeded criteria rule)",
@@ -1752,7 +1752,7 @@
17521752
"hydration-race"
17531753
],
17541754
"source": [
1755-
"packages/rest/src/rest-server.ts#registerSharingRuleEndpoints (registerSharingRuleEndpoints ~L7345-7494: list/create/get/delete)",
1755+
"packages/rest/src/rest-server.ts#registerSharingRuleEndpoints (list/create/get/delete)",
17561756
"packages/spec/src/security/sharing.zod.ts (criteria rule authoring + match-all refusal #3896)",
17571757
"packages/plugins/plugin-sharing/src/objects/sys-sharing-rule.object.ts + sys-record-share.object.ts",
17581758
"objectui packages/plugins/plugin-sharing/src/sharing-plugin.ts#nav_sharing_rules (nav_sharing_rules Setup nav → sys_sharing_rule)",

‎docs/qa/platform-checklist/areas/platform-core.json‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2163,7 +2163,7 @@
21632163
"objectui packages/app-shell/src/context/CommandPaletteProvider.tsx (⌘/Ctrl+K — wired)",
21642164
"objectui packages/components/src/ui/sidebar.tsx (SIDEBAR_KEYBOARD_SHORTCUT = 'b'), (the handler requires metaKey||ctrlKey — the source of the B-vs-⌘B display mismatch)",
21652165
"objectui packages/app-shell/src/layout/chatDockState.ts (matchChatDockShortcut — ⌘/Ctrl+Shift+I, composer-safe)",
2166-
"objectui packages/app-shell/src/console/ai/AiChatPage.tsx:~605-615 (matchAiChatShortcut — ⌘⇧O/⌘⇧S, PAGE-scoped)",
2166+
"objectui packages/app-shell/src/console/ai/AiChatPage.tsx (matchAiChatShortcut — ⌘⇧O/⌘⇧S, PAGE-scoped)",
21672167
"repo-grep evidence for the five dead accelerators: no handler for ⌘/ / N / R / ⌘E / ⌘D anywhere in app-shell, console or components (the only near-misses are page-scoped: ApprovalsInboxPage's plain `r` quick-decide and useDebugMode's Ctrl+Shift+D — neither matches an advertised accelerator)"
21682168
],
21692169
"history": [

‎scripts/check-platform-checklist.mjs‎

Lines changed: 24 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -764,12 +764,12 @@ const BATTERY_SOURCE_LINE_CITATIONS = 'selfTestSourceLineCitations: the `:NNN` r
764764
const BATTERY_SYMBOL_ANCHORS = 'selfTestSymbolAnchors: the anchor detector, the resolver and the floor';
765765

766766
const SELF_TEST_BATTERIES = Object.freeze({
767-
[BATTERY_TRAP_VOCABULARY]: 0,
768-
[BATTERY_PROVISIONING_USE]: 0,
769-
[BATTERY_UNREFERENCED_RECIPES]: 0,
770-
[BATTERY_META_CALL_SPELLING]: 0,
771-
[BATTERY_SOURCE_LINE_CITATIONS]: 0,
772-
[BATTERY_SYMBOL_ANCHORS]: 0,
767+
[BATTERY_TRAP_VOCABULARY]: 22,
768+
[BATTERY_PROVISIONING_USE]: 34,
769+
[BATTERY_UNREFERENCED_RECIPES]: 19,
770+
[BATTERY_META_CALL_SPELLING]: 53,
771+
[BATTERY_SOURCE_LINE_CITATIONS]: 19,
772+
[BATTERY_SYMBOL_ANCHORS]: 29,
773773
});
774774
const SELF_TEST_BATTERY_FLOOR = 6;
775775

@@ -1283,8 +1283,17 @@ export const NEIGHBOURING_MAP: Readonly<Record<string, string>> = Object.freeze(
12831283
// silent — HTTP status (`status:409`), config literals (`{maxRetries:3}`),
12841284
// ports (`http://localhost:3000`), clock times (`08:00`, `...T00:00:00Z`) and
12851285
// JSON quoted in prose (`{"scannedTypes":1}`). Each is pinned below.
1286+
//
1287+
// A THIRD branch was added by #13788, measured rather than reasoned: sweeping
1288+
// the ledger for anchorable citations turned up four line pins the two
1289+
// branches above do not reach — `AiChatPage.tsx:~605-615` (the tilde INSIDE
1290+
// the colon form, where the battery only ever pinned `~:`) and the `~L7246-7331`
1291+
// spelling, which carries no colon at all. Both read exactly like the class
1292+
// step (1) removed, and both sat green through it. The `L` form needs its own
1293+
// left boundary so an identifier ending in a capital L before digits
1294+
// (`SQL2019`) is not read as a line pin.
12861295
const SOURCE_LINE_CITATION =
1287-
/(?:\.(?:ts|tsx|mts|cts|js|mjs|cjs|json|jsonc|md|mdx|ya?ml|sql|css|html|sh|py|toml)|(?<![A-Za-z0-9_"])):\d+(?:-\d+)?/g;
1296+
/(?:\.(?:ts|tsx|mts|cts|js|mjs|cjs|json|jsonc|md|mdx|ya?ml|sql|css|html|sh|py|toml)|(?<![A-Za-z0-9_"])):~?\d+(?:-\d+)?|(?<![A-Za-z0-9_])~?L\d{2,}(?:-\d+)?(?![A-Za-z0-9_])/g;
12881297

12891298
/**
12901299
* @param {string} text
@@ -1322,6 +1331,11 @@ function selfTestSourceLineCitations() {
13221331
t('C5 an approximate `~:` citation is caught', n('computeAuthGate ~:5084-5160') === 1);
13231332
t('C6 a comma/slash-chained run is caught in full', n('storage-routes.ts:241-243,:255,:267') === 3);
13241333

1334+
// FIRES — the two spellings #13788 measured still in the ledger after step (1).
1335+
t('C7 a colon-TILDE citation is caught — the tilde inside the colon form', n('AiChatPage.tsx:~605-615') === 1);
1336+
t('C8 a `~L` line pin is caught, colon or no colon', n('registerRecordShareEndpoints ~L7246-7331') === 1);
1337+
t('C9 a bare `L` line pin is caught', n('the evaluate leg L7477-7493') === 1);
1338+
13251339
// STAYS SILENT — the neighbours that share the colon-then-digit shape.
13261340
t('S1 an HTTP status in prose is not a citation', n("thrown {code:'DELETE_RESTRICTED', status:409}") === 0);
13271341
t('S2 a config literal is not a citation', n('retry {maxRetries:3, backoffMs:1000}') === 0);
@@ -1330,6 +1344,9 @@ function selfTestSourceLineCitations() {
13301344
t('S5 JSON quoted in prose is not a citation', n('a 200 {"scannedTypes":1,"stats":{}}') === 0);
13311345
t('S6 an ADR section reference is not a citation', n('ADR-0025 §3.3 and #13479') === 0);
13321346
t('S7 the README placeholder spelling of the ban is not itself a citation', n('never pin `file.ts:NNN` or a bare `:NNN`') === 0);
1347+
t('S8 a capital L ending an identifier before digits is not a line pin', n('SQL2019 and a TTL3600 budget') === 0);
1348+
t('S9 an i18n-style token is not a line pin', n('the L10n bundle') === 0);
1349+
t('S10 a one-digit `L` reference is not a line pin — the floor is two digits', n('lane L1 of the queue') === 0);
13331350

13341351
citationsReachedVerdict = true;
13351352
return { failures, checked };

‎scripts/checklist-symbol-anchor-baseline.json‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
"$comment": "Symbol-anchor floor for docs/qa/platform-checklist/ — the shrink-never population of `path/to/file.ts#symbol` citations that scripts/check-platform-checklist.mjs resolves against real source. Authored from `node scripts/check-platform-checklist.mjs --anchor-census` (#13788, step (2) of #13482's ruling). Each entry is the count of anchors that RESOLVED in that family file; adding anchors is ordinary work and never reds. A count that falls below its floor means citations gave up the one half this gate can read, which is the silent remedy every red here would otherwise have.",
33
"$authority": "⛔ MAINTAINER-ONLY: lowering a floor is a maintainer's call. Retiring items legitimately removes anchors — that is the case a maintainer rules on, per instance, and never the author's way past a red.",
44
"floors": {
5+
"README.md": 1,
56
"areas/access-security.json": 44,
67
"areas/ai.json": 18,
78
"areas/api-backend.json": 41,

0 commit comments

Comments
 (0)