Skip to content

check:objectql-double-limit declares no population over the packages/**/*.test.ts corpus it walks, so dispatch-gates can never name it for a test-file card #12410

Description

@yinlianghui

Filed unassigned while measuring #12173 (finding ①). Not claimed, not graded.

What was measured

scripts/check-objectql-double-limit.mjs walks packages/**/*.test.ts:

const SCAN_ROOT = 'packages';          // :231
...
else if (/\.test\.ts$/.test(entry)) acc.push(p);   // :714
for (const abs of testFilesUnder(join(repoRoot, SCAN_ROOT))) { ... }   // :727

The only path literals extractWatchHints recovers from it are scripts/objectql-double-limit.baseline.json and n/a — the bare single-segment 'packages' is not recovered at all, and would not cover a nested path even if it were:

$ node -e "... m.extractWatchHints(src)"
hints: ["scripts/objectql-double-limit.baseline.json","n/a"]
hintCovers('packages','packages/objectql/src/a.test.ts')  -> false
hintCovers('packages/**','packages/objectql/src/a.test.ts') -> true

Consequence, on a fully current tree (origin/main = b000ab59bb), for a test-file card:

$ node scripts/pm/dispatch-gates.mjs 'packages/plugins/plugin-email/test/send.test.ts'
   # 175 families discovered; check:objectql-double-limit absent from "Local gates for this card"

$ node scripts/pm/dispatch-gates.mjs --residue 'packages/plugins/plugin-email/test/send.test.ts'
  - pnpm check:objectql-double-limit   [lint.yml]   names: scripts/objectql-double-limit.baseline.json, n/a

It is in the residue, not the family. Nor is it in CHANGE_KIND_GATES — its two nearest siblings, check:engine-double-contract and check:where-matcher, which walk the same *.test.ts corpus for the same class of fake-engine double, both are under the adds or edits a test file kind.

Why this matters

#12173 records a dev being broadsided on check:objectql-double-limit and attributes the miss to branch-tree staleness (the gate landed on main after the branch was cut). That attribution is incomplete: on today's tree, with the gate fully present, the derivation still cannot name it for a test-file change. Deriving the family list against the merge base would move it from "not discovered" to "discovered, then dropped into residue" — the dispatch prompt would still not carry it.

The fix this repo has already decided

The tool's own residue note prescribes it, verbatim:

Read the gate before treating it as one. If it scans packages, the fix belongs there: declare the scan surface beside the roster (the subtree spelling, packages/**), after which it is MATCHED here.

Same class as #10790 (check:parse-guard, bare scripts refused as too generic) and #10648 (check:doc-authoring, four bare-word population roots), both closed by declaring the subtree spelling in the gate.

⚠️ Whoever takes this should re-derive the residue after the change and check the opposite direction too: packages/** matches ~every package card, so the cost of declaring it is that this gate joins a very large number of families. If that cost is judged too high, the CHANGE_KIND_GATES route (beside its two siblings under adds or edits a test file) is the alternative — the two routes produce different maintenance shapes and the choice is a judgment call, not a mechanical one.

Also observed while here

Lint & Repo Gates still runs 120 named steps sequentially with no continue-on-error key anywhere in the job. Re-derived at b000ab59bb: check:where-matcher at lint.yml:2768, the ObjectQL double limit gate step immediately after it at :2789, and 10 further gate steps in that job after it — #12173 recorded 46 at the time of filing. That half is #12173's finding ②; recorded here only because the number moved.

Activity

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

Metadata

Metadata

Assignees

Type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions