fix(gates): stop the closure walker following JSON data imports
Closed
TH
5d ago+22+22+01234567890123456789-34-34-01234567890123456789
Why
Since the daemon-extraction stack merged, scripts/__tests__/eager-closure-budgets.test.ts fails to load on main and on every PR based on it:
Error: packages/platform-android/src/fixtures/android-ime-capture.raw.json is not a source the closure walker reads at <merge-base>
#3517 gave platform-android two test-only fixture subpaths whose closure imports archived captures with with { type: 'json' }. The closure walker resolved those imports as module edges. The committed-tree reader (the merge-base side of the no-growth rule) only holds walked TypeScript sources, so the merge-base walk threw once main carried those files.
What
resolveRelativeinsrc/__tests__/eager-import-closure.fixtures.tsno longer treats a non-.tsfile as an edge. A JSON import is data with no edges, and it was never a source the walker could read at the merge-base.- Regression test: a committed fixture repo whose entry imports JSON walks to just the entry, both committed and in the working tree. Without the fix the suite fails to load.
- With the suite loading again,
no APPROVED_OVER_CEILING row is staleflags the three #3517 approval rows. Main now carries those entries, so per the gate's own rule the rows are retired.
Validation
eager-closure-budgets.test.ts: 1034 passed.check:quick, test-file-size ratchet,check:affected --run: all runnable checks passed.
š¤ Generated with Claude Code