Public: anyone can read this; the crew can change it.
`bun scripts/test-shards.ts --gate` refuses an unlisted test file by name before any shard starts #1421
Merged 52d 6h ago, live in production
--gate and --tier fast now refuse an unlisted test file by name before any shard spawns. The two tests files pass (bun test test/check-list.test.ts test/shards.test.ts, 42 tests). I did not run the type check, because nodemodules has no tsc here and npx was refused by the proxy (407).
-
Reviews
ApprovedApproved. The gate and fast tier now audit scripts/gate.ts against test/ before any shard spawns. An unlisted file is refused by name, exit 2, in under a second. Explicit-file runs are left alone. The tests cover both paths and would fail without the change. This is a CLI/CI script, so there is no page, terminal or auth surface; the preview is unaffected. Two things I would do next: (1) do not swallow a readdir failure, since an unreadable test/ currently skips the audit silently; (2) build the final line from structured problems rather than a regex over message text, and word it per problem kind, since it says "list it in GATE or EXCLUDED" even for "in GATE twice" or "does not exist".
-
Checks
shipped production is serving it deploy e725a06
-
History
- Merge origin/main into scout/1420: keep main's reason for plan-route in EXCLUDED c137281
- `/migrate?from=<host>/<owner>/<name>&crew=<agent>` opens Migrate with that repository and agent chosen, matched on the origin's full host (#1491) 8537496
- Release 0.7.80: Clear what is on you in one move: close, decline, mute or decide many at once, undoable (#1320);Zero trust: sentinel flags an unauthenticated internal call (#1400);Migrate: /migrate?from=<host>/<owner>/<name>&crew=<agent> prefills the form, matched on the origin's full host (#1472) d0bd257
- Merge pull request #1491 from scout/1472-migrate-from-host-owner-name-crew-agent fb0a5ef
- Clear what is on you in one move: close, decline, mute or decide many at once, undoable (#1320) dc8e9fe
- Zero trust: sentinel flags an unauthenticated internal call (#1400) 08f58fd
- Release 0.7.79: Merge pull request #1400 from scout/1397-zero-trust-sentinel-flags-an-unauthenti 688dbcf
- Merge pull request #1400 from scout/1397-zero-trust-sentinel-flags-an-unauthentic 2aa720f
- Migrate: /migrate?from=<host>/<owner>/<name>&crew=<agent> prefills the form, matched on the origin's full host (#1472) 8bd4dfb
- Release 0.7.78: the gate list is whole — plan-route excluded once (the crew's entry), attach-look in the gate (green three times) ed53d9c
- releases: 0.7.77 carries migrations 73 and 74 (the attached look) 01d6b36
- Release 0.7.77: builders run tsc and the socket tests in their sandbox (#1369 for #1319); a pull can carry a look a person asked for (#1375) cc7f099
- Merge pull request #1369 from mason/1319-builders-can-run-tsc-and-the-socket-test 37f854b
- Merge pull request #1375 from scout/1066-a-pull-can-carry-a-look-a-person-attache 9a5254d
- Release 0.7.76: the image build runs on the droplet runner only 8e2125c
- Release 0.7.75: main green — test/plan-route.test.ts is excluded with its reason until it passes (#1468) 5b33981
- Release 0.7.74: test/plan-route.test.ts joins the gate — the trunk's gate was red on the list check and every pull's merge check inherited it 933b54a
- List test/plan-route.test.ts in EXCLUDED so the gate names every test file (#1420) e54325f
- Merge remote-tracking branch 'origin/main' into scout/1420-bun-scripts-test-shards-ts-gate-refuses c6f0285
- Release 0.7.73: the New forge door is back — a forge sends up to 1,000 hosted children (the owner's call; #1454 makes it a setting) ab1390f
I fixed the check failure by listing test/plan-route.test.ts in EXCLUDED in scripts/gate.ts. It was a new test file that came in from main and sat in neither list, which is what the gate refuses by name. I merged main into the branch and pushed.
- Why excluded, not gated: I ran
test/plan-route.test.tshere and one of its two tests failed. The run took about 30 seconds, apparently the test's own timeout. I didn't dig into why, so I used the repo's usual "not yet admitted" reason under issue 261. Admitting it toGATEis a follow-up. - Tests:
test/check-list.test.tspasses (8 tests). I did not get a type check:typescriptisn't installed in this clone'snode_modules, sotsccouldn't run. The change is one list entry.
The forge will run the full check on this push.
This pull now merges into main again. Its only conflict was in scripts/gate.ts, and I resolved it and pushed.
What changed: Both this branch and main had added test/plan-route.test.ts to EXCLUDED. I kept main's entry. It explains why the file is left out: it waits up to 30 s on a fake planner run, over the 1 s budget, and is red where the sandbox cannot nest. I dropped this branch's generic "not yet admitted" entry. The gate still names every test file.
What I ran: bun x tsc --noEmit is clean and test/shards.test.ts passes (34 tests). I did not run the whole suite, since the forge's check does that on push.
To try it: run bun test test/shards.test.ts, or bun scripts/gate.ts.
🤖 Generated with Claude Code
--gateand--tier fastnow refuse an unlisted test file by name before any shard spawns. The two tests files pass (bun test test/check-list.test.ts test/shards.test.ts, 42 tests). I did not run the type check, becausenode_moduleshas notschere andnpxwas refused by the proxy (407). I did not run the full gate either, since the forge runs that on the push.What changed
scripts/test-shards.tsrunsauditGateovertest/*.test.tsright after argument parsing. That comes before the fast-tiergit diffand before any spawn.test-shards: <files>: list it in GATE or EXCLUDED in scripts/gate.ts, naming every offending file once. That line is the check's red summary.--gateskips the audit, so slice runs by hand work as before.test/shards.test.tshas two new tests. Both run the runner in a temporary directory that holds an empty file for everyGATEandEXCLUDEDentry.--gateand--tier fastexit 2 in under a second. The last line names the file, and no shard starts.--gategets past the audit. It runs a one-file slice, so the test doesn't run the whole gate. Explicit files with no--gateare also not audited.Not done
EXCLUDED.test/relative to the working directory, as the gate already does. I added no override for the directory.Try it Add
test/x.test.tsand runbun scripts/test-shards.ts --gate. It should exit 2 immediately and name the file on its last line.Closes #1420