Skip to content

test(spec): the first data/ file group's test titles state each cited decision in words instead of a tracker number (stage 15) - #21810

Merged
objectstack-fleet[bot] merged 2 commits into
mainfrom
claude/issue-20749-test-strings-f
Oct 5, 2026
Merged

objectstack-fleet[bot] merged 2 commits into
mainfrom
claude/issue-20749-test-strings-f

Conversation

@objectstack-fleet

Copy link
Copy Markdown
Contributor

Part of #20749
Clause-②: no

Stage 15 of this card: the next area of class (e), the test strings shipped under packages/spec/src, as ruled in 5902360492 on #20513. This stage takes the first name-ordered file group directly under packages/spec/src/data/: the 20 test files from aggregate-field-type-compatibility.test.ts to date-range-presets.test.ts. They carried 94 messages and 102 tracker ids, citing 60 records. Every one of those ids now either states what its record decided, in words (form D), or is dropped where the title already says it. Text only: no assertion, identifier, test count or code comment changes.

Census at the base (0a3480311a)

Instruments: census10.cjs (md5 9d08602ab972b4b8643c90d64d40fa41), census.cjs (md5 6e42a45a926d375013c32d62f16a296e), census-wide.cjs (md5 c98410a19529c439adb0afbfb00026a2) and dirtable.cjs (md5 dda605c54745b4a60cc14c9a686e4eff). They are byte-identical to the copies stages 10 to 14 used. A literal counts as a test title when its folded message is argument 0 of a describe / it / test call, .each / .skip / .only chains included. Everything else is an "other" string.

Both instruments read 1325 messages / 1406 ids in 282 files, the seat's reading at 0a3480311a (stage 14's head).

directory files messages / ids titles other
data/ (this PR: the first 20 files) 95 468 / 501 445 / 475 23 / 26
ui/ 81 393 / 416 375 / 398 18 / 18
api/ 40 189 / 201 181 / 193 8 / 8
system/ 34 154 / 165 128 / 138 26 / 27
(files directly in src/) 30 118 / 120 117 / 119 1 / 1
ai/ 1 2 / 2 0 2 / 2
contracts/ 1 1 / 1 0 1 / 1
total 282 1325 / 1406 1246 / 1323 79 / 83

The group reads 94 messages / 102 ids in 20 files, the seat's figures, file for file:

file (under data/) messages / ids titles other
aggregate-field-type-compatibility.test.ts 4 / 4 4 / 4 0
analytics-date-range-closed-vocabulary.test.ts 1 / 1 1 / 1 0
analytics-date-range-two-bound-window.test.ts 3 / 3 3 / 3 0
analytics-query-window-integer.test.ts 2 / 2 2 / 2 0
analytics-strictness-batchd.test.ts 9 / 9 9 / 9 0
analytics.test.ts 6 / 6 6 / 6 0
api-derivation.test.ts 6 / 6 6 / 6 0
api-methods-batch-conformance.test.ts 3 / 4 1 / 1 2 / 3
authoring-key-lint.test.ts 2 / 2 2 / 2 0
autonumber-format.test.ts 3 / 3 3 / 3 0
autonumber-unanchored-boundary.test.ts 3 / 4 3 / 4 0
bulk-write-hook-conformance.test.ts 2 / 2 2 / 2 0
calendar-day.test.ts 2 / 2 2 / 2 0
context-tokens.test.ts 1 / 1 1 / 1 0
currency-mode-family-closure.pin.test.ts 2 / 2 2 / 2 0
currency-precision-iso4217.test.ts 7 / 7 7 / 7 0
data-engine.test.ts 20 / 25 20 / 25 0
datasource-credential-redaction.test.ts 6 / 6 6 / 6 0
datasource.test.ts 10 / 10 10 / 10 0
date-range-presets.test.ts 2 / 3 2 / 3 0
20 files 94 / 102 92 / 99 2 / 3
  • Controls. Lit, a title: data/document.test.ts reads 2 / 2 at the head. Lit, "other" strings: the two in data/external-lookup-retirement.test.ts (:89, :130) still read at the head. Dark: the file comment at data/analytics-strictness-batchd.test.ts:4 (it names the strictness batch by its number) reads 0. Planted in a scratch copy of the head data/calendar-day.test.ts: an id put into a title reads 1 / 1, and an id put into a comment reads 0.
  • A wider pattern (any # plus digits) reads the same totals in 19 of the 20 files. In aggregate-field-type-compatibility.test.ts it reads one more, a decision-batch number at :150 that sits beside a cited record in the same literal. The gate's pattern needs three to five digits, so it is not counted there.
  • At the head: 1231 messages / 1304 ids in 262 files. The 20 files read 0 / 0 on both patterns, and no other file moved.

How the area was chosen

data/ has no subdirectory to split by (449 ids directly under it, data/driver/ 52), so its stages take name-ordered file groups near the ~100-id bound, as stage 14's report proposed. This census reads the first group at exactly 102, the claim's figure, so the rule needed no re-cut.

Named for the next stages (re-cut from the head census, 1231 / 1304; data/ 374 / 399 left):

  • data/ in four more stages, name-ordered:
    1. default-value-shape.test.ts to filter-comparand-shape.test.ts: 20 files, 94 messages / 100 ids;
    2. filter-comparand-type.test.ts to filter-view-operator-parity.test.ts: 20 files, 95 / 99;
    3. filter.test.ts to object.test.ts: 17 files, 103 / 114. object.test.ts alone carries 42, so no cut lands nearer the bound;
    4. query-transport.test.ts to validation.test.ts (11 files, 34 / 34) with data/driver/ (7 files, 48 / 52): 86 ids.
  • ui/ 416, about four stages. api/ 201, two. system/ 165, two. The files directly in src/, 120, one.
  • The three docblock needles (ai/build-progress.test.ts:236, :237, contracts/approval-service.test.ts:274), one stage with their docblocks.

What each id became

24 literals (28 ids) now state a decision in words. 2 literals (2 ids) get their subject back in words where the number stood in for it. 69 literals (72 ids) drop a number the title already explains. (95 literals in 94 messages: the sys_organization reason string is one message over two lines.)

Every cited record was read with its comments through REST: 55 answer 200. #6345, #8876, #9040, #10194 and #17014 answer 404, and their decisions were read from what landed: e2798fa (one driver vocabulary for start and migrate), d634e66 (the username half of the URL userinfo grammar), 2420641 (a credential in the mongo options passthrough is refused), 2306a76 (theme / analytics_cube validated at the /meta write door) and 80aef80 (a one-day window for the one-day presets), each with its CHANGELOG entry. No cross-repo record is cited in this group.

record(s) literal (under data/) now reads
#11152 aggregate-field-type-compatibility.test.ts:150 "accepts sum / avg / min / max over booleans — numbers on every backend, a ruling that outranks the refused-by-default rule". The maintainer ruled that booleans aggregate as numbers on every backend; decision batch 80 held that ruling over batch 59's blanket refusal of unnamed pairs. That batch number went with the id.
#4001 (3) analytics-strictness-batchd.test.ts:83, :248, :306 "batch D, unknown keys refused — …" before "the doors the cube family is reachable through", "alias claims are true of the surfaces they point at" and "deliberate non-closures (re-verdicts, not omissions)". The campaign's decision: an unknown key is refused, not stripped.
#3878 (2) analytics-strictness-batchd.test.ts:270, :297 "matching the dispatcher's bespoke hint at the /analytics entry" and "the retired-envelope tombstones still fire". The body is the bare AnalyticsQuery; the { cube, query } envelope was retired with tombstones, and the entry answers 400 with a hint at where.
#18612 analytics.test.ts:314 "a persisted cube heals at the door — the retired join sql / relationship are stripped (ADR-0087 D2)".
#3391 api-derivation.test.ts:16 "api-derivation — one table resolves the effective operations from six primitives". The server is the only adjudicator, through one derivation table.
#3543 api-derivation.test.ts:286 "vocabulary split — authors write six primitives, the wire speaks operations". The authored enum shrank; the wire vocabulary stayed byte-stable.
#15873 api-methods-batch-conformance.test.ts:221 A declared reason string: "(a ruling grants update; both are column-clamped per row by ADR-0092 D2)". Option (a), decision batch 64.
#3786 authoring-key-lint.test.ts:37 "lintAuthoredRecordKeys — an unknown authoring key is reported, not swallowed", the decision its source docblock records.
#6555 autonumber-format.test.ts:23 "DEFAULT_AUTONUMBER_FORMAT / resolveAutonumberFormat — one declared default both sides read". Route 3: {0000} became the contract default, and both fallbacks went away.
#5038 bulk-write-hook-conformance.test.ts:114 "records the after half as DELIVERED — the engine fires it once per row".
#5574 bulk-write-hook-conformance.test.ts:119 "records the before half as DELIVERED — the engine dispatches it per row too".
#20126 currency-mode-family-closure.pin.test.ts:348 "currency-mode family — the enumerating closure pin: defaultCurrency holds only under fixed".
#19992 currency-precision-iso4217.test.ts:163 "the removed currencyConfig.precision at rest: a stored row carrying the baked precision: 2 is served canonical".
#7918 currency-precision-iso4217.test.ts:224 "… where the ISO 4217 width check used to refuse it". That check was the record's option A, later reversed.
#3407, #6437 data-engine.test.ts:1185 "DroppedFieldsEventSchema.reason — why a write dropped submitted fields, widened past the readonly pair".
#6262, #6433, #6435 data-engine.test.ts:1198 "primary_key is the value the engine reports when it strips a payload id it ruled is not an identifier", the schema's own wording of that strip on the bulk and the by-id paths.
#8300 datasource-credential-redaction.test.ts:70 "(the drift guard on the one credential-key definition)".
#8876 datasource-credential-redaction.test.ts:232 "— the username half of the same alignment".
#8337 datasource-credential-redaction.test.ts:243 "redactUrlCredentialQueryParams — the read half: a credential query parameter is never served back".
#8153 datasource.test.ts:673 "— unchanged by the managed-row credentialsRef allowance". The ruling allowed external.credentialsRef, and only it, on managed rows.
#4614, #8793 date-range-presets.test.ts:14 "date-range preset vocabulary — one source of truth, read by both the UI and the data side".

Subject restored (2 ids): #20126 at currency-mode-family-closure.pin.test.ts:403 ("currency-mode closure controls — each rule can fail, and passes what it must") and #7918 at currency-precision-iso4217.test.ts:311 ("carries the measured anchors — 0 digits for JPY, 2 for USD, 3 for KWD"). That literal moved from double to single quotes, since it no longer holds an apostrophe.

Dropped only (72 ids): #1603, #2377, #3026, #3391, #3543, #3545, #3795 (9), #4001 (2), #4286, #4346 (2), #4538, #4583, #5586, #6345, #6555, #6560, #7178 (5), #7265, #7287 (2), #7802 (2), #8032, #8057 (2), #8153 (7), #8336, #8337, #9040, #10194, #10414, #13802, #16041, #16632, #17014, #17296, #17598 (2), #18278, #19992 (3), #20011, #20300 (2), #20550, #20600, #20808 (3), #21365 (2).

Readers

  • Test-name filters: none. A tracked-tree search for -t and --testNamePattern finds only packages/qa/dogfood/README.md:142 (-t "owner-scoped"), which is unrelated.
  • Snapshots: none. No __snapshots__ directory exists under data/, and no .snap file is tracked under packages/spec.
  • Projects: two touched files are listed in packages/spec/vitest.repo-tests.json: api-methods-batch-conformance.test.ts and currency-mode-family-closure.pin.test.ts. Both were run in the repo project at the base and at the head, and the other 18 in local.
  • By substring: every old literal, plus a window around each id (289 needles), was searched across the tracked tree outside its own file. No gate, doc, filter, snapshot or scripts/check-*.mjs self-test reads one. The 14 hits are:
    • sibling titles in other lanes: service-analytics aggregate-nontemporal-measure-refusal.test.ts:344 and objectql engine-autonumber-default-format.test.ts:248;
    • this card's later data/ stage: data/driver/postgres.test.ts:169, the same "placeholders are not resolved here" title, already in the census;
    • comments, CHANGELOG, an audit ledger and liveness evidence: lint validate-dataset-measure-aggregates.test.ts:179, service-analytics dataset-compiler.ts:227, objectql engine.ts:6206 and :6272, analytics.zod.ts:1002, docs/audits/2026-07-unknown-key-strictness-ledger.md:728, two packages/spec/CHANGELOG.md entries and the liveness/field.json:218 evidence string, which quotes the engine.ts comment. None reads a test title.
  • Same-text titles named in stage 14's ACCEPT ((#15680), (#5955), #3896 close-out): none falls in this group.

Text-only proof

Stage 10's scratch tool (textonly10.cjs, md5 d5e4801dbb4329ab1984da91e92fc47c) compares base and head file by file on three legs:

  1. Skeleton: the full AST, with string pieces masked. It must be identical.
  2. Comments: every comment, byte-equal.
  3. Strings: each changed string leaf must sit in a test-call title position or on a declared line, must carry a tracker id before, and must carry no # plus digits after. The declared lines are the three reason-string leaves in api-methods-batch-conformance.test.ts.
  • Result: 20 of 20 files SAME on all three legs, as predicted in writing before the run.
  • Totals: 95 changed literals, 92 titles and 3 declared. The diff's + and - lines are exactly the 95 planned lines, and every file keeps its line count.
  • Controls (10 of 10 as predicted, on scratch copies, each anchor hit once): identifier rename DIFF; numeric literal DIFF; comment edit COMMENT DIFF; a non-title string given an id VIOLATION; a rewritten title given a new id VIOLATION; a title that was id-free at base edited VIOLATION; one title reverted to base SAME; a declared string given a new id VIOLATION; an undeclared expect message changed VIOLATION; a title re-split into a + chain DIFF.

Test counts: the 20 files were run at the base, in a separate base worktree, and at the head, with --project local --project repo. Both sides read 553 / 553 passed, with the same count and status sequence per file in 20 of 20. 291 full test names change, and each equals the base name with the planned replacements applied (0 mismatches). No full name repeats on either side.

main merged in, once

#21800 (the console pin bump) landed while this branch was being verified, and it rewrites the comment block at :61-77 of api-methods-batch-conformance.test.ts. This PR edits only string literals in that file, more than 100 lines below the block, so origin/main (18c2ddc1ec, which also carries #21801) was merged in with a plain merge, no rebase, and no conflict. The PR's delta against main is still exactly the 20 files, +95 / -95. Every reading in this body was re-taken on the merged head bf16ad1190, against 18c2ddc1ec as the base: the census (1325 / 1406 there, 1231 / 1304 here, unchanged by the two commits), the text-only proof and its controls (the three declared lines now sit at :202, :230 and :235), the 20-file runs, the full build, the suite, the typecheck and the gates. Re-fetched just before this PR opened, origin/main was one commit further (75ddcd1b41, #21805, in cloud-connection, metadata-core and runtime). It touches no packages/spec path and no file here, so it was not merged.

Changeset: skip-changeset

Measured, not assumed:

  • npm pack --dry-run of @objectstack/spec lists 2068 files. 0 of the 20 touched files are in it, and no *.test.ts at all. Of src/, only the *.zod.ts sources ship: the controls src/data/analytics.zod.ts, src/data/data-engine.zod.ts and dist/data/index.js are in it.
  • In the built dist/, five new phrases and four old literals each read in 0 files. The control Unrecognized key(s) on reads in 42.

So this PR publishes nothing, and no changeset is added.

Verification (at bf16ad1190)

  • pnpm turbo run build over all packages: 71 / 71 (also 71 / 71 at the pre-merge head 89c4b300c2).
  • @objectstack/spec:
    • vitest run --project local: 615 files, 18360 passed, 1 todo.
    • typecheck exit 0, including check:test-typecheck (52 files / 246 errors / 135 pinned signatures held). Its program holds all 20 touched files, counted with tsc --listFilesOnly -p tsconfig.test.json.
    • check:generated: all 15 generated artifacts up to date after the merge.
  • Gates: dispatch-gates --commands derived 79 families, the same set as stages 13 and 14, and all 79 exit 0. --ran reconciles: 79 derived, 79 run, 0 NOT-MEASURED, 0 UNRUN.
    • The five roster families whose rosters sit under a touched directory were also run, and each exits 0: check:meta-url-spelling, check:spec-changes, check:authz-resolver, check:error-code-casing and check:filter-alias-parity.
  • ESLint, a proven narrowing: --no-inline-config over the 20 files reads 0 errors and 0 warnings. The population comes from ESLint's own config: 20 configured, 0 ignored. No file sets parserOptions.project or projectService, so no untouched file's verdict can move.
  • check-governed-merges --test: NOT governed, 190 changed lines.

Acceptance notes

  • No needle in this group. Every id was a title or a declared reason string; no expected value of an assertion over a source docblock was found. The three known needles are untouched.
  • Same-id test titles in other packages are their lanes' test-string shares. A search of describe / it / test lines outside packages/spec finds 156 lines citing ids this PR handled, in 79 files of 23 packages: objectql 73 (29 files), rest 18 (7), runtime 7 (4), plugin-security 6 (5), cli 6 (3), lint 6 (4), service-datasource 6 (3), driver-sql 4 (4), platform-objects 4 (2), plugin-approvals 3 (2), service-automation 3 (2), driver-mongodb 3 (1), plugin-auth 3 (1), service-analytics 3 (3), metadata-core 2 (1), plugin-hono-server 2 (1), and one each in client, triggers, core, metadata-protocol, qa/dogfood, types and driver-memory.
  • Two spec test files outside src/ carry same-id titles: packages/spec/scripts/file-description.test.ts:66 and packages/spec/scripts/format-type.test.ts:85. They are outside class (e) as ruled ("the test strings shipped under src/").
  • Numeric delivery fields: bulk-write-hook-conformance.test.ts:115-116 and :129-130 assert engineDeliveryIssue: 5038 / 5574, numbers in the source contract table. They are not strings, the gate's pattern cannot see them, and they are not this card's share.
  • Code comments still carry ids in these files and their sources, for example the header of analytics-strictness-batchd.test.ts and the SINGLE_RECORD_WRITE_ONLY comments in api-methods-batch-conformance.test.ts. Comments are not this card's share, and none is touched here.

Generated by Claude Code

claude added 2 commits October 5, 2026 03:04
… decision in words instead of a tracker number (stage 15)

Twenty test files directly under packages/spec/src/data/, name-ordered from
aggregate-field-type-compatibility.test.ts through date-range-presets.test.ts:
94 messages / 102 ids. Each id becomes a statement of the decision the cited
record made, or is dropped where the title already says it. Text only: no
assertion, identifier, code comment or non-test file changes, and every file
keeps its line count.

Claude-Session: https://claude.ai/code/session_01T9u38rswFp5Rw8DswRUReJ
Co-authored-by: Claude <noreply@anthropic.com>
@objectstack-fleet objectstack-fleet Bot added the skip-changeset PR has no user-facing published change; bypasses the changeset gate label Oct 5, 2026
@github-actions

github-actions Bot commented Oct 5, 2026

Copy link
Copy Markdown
Contributor

📓 Docs Drift Check

Nothing in this diff resolved to a documentable surface (no symbol, route or SDK anchor derived from 0 changed package(s)), so this run has no opinion about the docs.

What this run could not see

Coarse fallback — 0 page(s) merely mention a changed package (the pre-#9192 predicate, kept for the deliberately-wide backstop): node scripts/docs-audit/affected-docs.mjs --json 75ddcd1b41e74823b7bb9f3fe9e159a189fa2a91 → packageMentionDocs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

protocol:data size/m skip-changeset PR has no user-facing published change; bypasses the changeset gate tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants