Repository navigation
test: isolate root-suite shared state - #1271
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
CI timings
Sum of wall clock: 52s · sum of compute: 52s Shard breakdown
updated 2026-08-29T20:09:59Z · |
📊 Docker image sizes (uncompressed, amd64)
🔴 1 regression
updated 2026-08-29T20:08:20Z · run · swarm script |
|
Lead review — no changes requested. Scope is minimal and matches issue #1266: two test files fixed for state leakage, plus one exported The env-restore fix is the right root cause: assigning CI green on ba6408e (both sharded The parallel-mode panics are correctly left alone and attributed upstream (Bun 1.4.0, oven-sh/bun#39783 / #39852, scanner FD-leak fix landed post-1.4.0 in #40016) rather than papered over with a repo workaround. That means Not merging: swarm policy requires explicit authorization. Ready for @tarasyarema. |
Summary
artifact-sdk.test.ts.Serial contamination
Artifact SDK → Codex OAuth
artifact-sdk.test.tssaved optional environment variables and restored them with assignment. WhenMCP_BASE_URLwas originally absent, assigningundefinedtoprocess.env.MCP_BASE_URLstored the literal string"undefined". The later Codex OAuth sweep inherited that value and failed while constructing its lock URL.Minimal reproducer before the fix:
After the fix:
43 pass / 0 fail.The fix is in the contaminating test and restores the original environment state exactly: absent keys are deleted, while present values are reassigned.
Slack production handler test → thread buffer
slack-assistant-comention-production.test.tspopulatedcachedBotUserId,cachedBotId, andswarmThreadRootCacheinslack/handlers.ts. Those module-level caches survived intoslack-thread-buffer.test.ts.Minimal reproducer before the fix:
After the fix:
31 pass / 0 fail.The production test now explicitly owns cache setup and teardown through a narrow testing reset. The affected thread-buffer test does not depend on ambient state.
Full serial result
Bun 1.4.0, 506 files:
7991 pass / 7 skip / 3 fail7994 pass / 7 skip / 0 failBoth affected files also remain green in isolation: Codex OAuth
6/6; Slack thread buffer25/25.Parallel verdict: upstream Bun 1.4.0
This half is upstream, not a repository port/tmpdir collision.
Taras's consecutive four-worker runs produced different failure sets (
41 fail / 2 errors, then99 fail / 3 errors) with Bun child-process panic output. On this SHA, the same command completed7994 pass / 7 skip / 0 failin 95.89s. The divergent failure sets plus a green repetition are nondeterministic.The failing surface is spawn-heavy, but the repository audit found no literal hard-coded
.listen(...)orBun.serve({ port: ... })calls in tests; network tests use the shared allocation helpers, and subprocess temp directories are uniquely named.Bun 1.4.0 has matching upstream reports:
mock.modulefollowed by enoughBun.spawncalls reachesEBADFand panicsNo repository workaround is included.
Verification
bun install --frozen-lockfilebun run lintbun run tsc:checkbun run test:root—7994 pass / 7 skip / 0 failbun run test:root -- --parallel=4—7994 pass / 7 skip / 0 failbun run check:bun-versionbash scripts/check-db-boundary.shbash scripts/check-test-spawn-sync.shbash scripts/check-audit-columns.shbun run check:dep-graphCI's sharded
test:rootis green onba6408ee: both shards passed on attempt 2. Attempt 1's shard 1 hit an unrelated existing migration-117 test timeout at 10 seconds; that file passed locally in 651 ms and the failed shard passed unchanged on its single rerun.Fixes #1266