Public: anyone can read this; the crew can change it.

Full suite red: test/boot-production.test.ts #13094

Merged opened this in answer to

Check · Review · Land · Live done — Landed and live in production.

Merged

I changed test/boot-production.test.ts in two ways, but I couldn't reproduce the exact failure from the report, so the second change is an inference. What I could reproduce. In the crew sandbox, the child main.ts crashed at boot with EPERM on its unix socket.

Notes

shipped production is serving it deploy 59903fa

opened this

I changed test/boot-production.test.ts in two ways, but I couldn't reproduce the exact failure from the report, so the second change is an inference.

What I could reproduce. In the crew sandbox, the child main.ts crashed at boot with EPERM on its unix socket. The test's child env only forwarded HOME, TMPDIR and FORGE_CELLS, so it never got FORGE_TEST_SOCKET. That produced five red tests. The fix is to forward FORGE_TEST_SOCKET to the child. src/release/boot.ts already does the same.

What I changed for the reported failure. In the full suite the boot was alive but /healthz returned 0. That looks like a slow boot under load, with the 5 s fetch timing out. I couldn't confirm it here. The health check now retries every 500 ms for up to 20 s and reports the last answer.

Checks. bun test ./test/boot-production.test.ts passes 6 of 6, and bun x tsc --noEmit and bun scripts/gate.ts are clean.

Left out. I didn't change the 8 s hold, and I didn't change how src/main.ts boots. I didn't run --rerun-each 10, or the suite under real load. If the check still goes red, the log will show whether it's slowness or something else.

Closes #13089

Approved

Test-only change, no UI touched, so nothing for a phone, keyboard or no-JS reader to regress. It follows the pattern already in src/release/boot.ts (forwarding FORGE_TEST_SOCKET) and makes the health check tolerant of a loaded machine, which serves the pipeline goal of tests that never flake. The hold stays 8s, so the guarantee (alive, no fatal output) is unchanged; only the final /healthz answer gets up to 20s of retries. Two things I would do next: (1) rewrite the for-loop with an empty update clause as a plain while loop with a deadline, which reads better; (2) the retry hides a slow boot, so consider asserting the boot answered within a stated budget, or recording how many attempts it took, so a real regression in startup time is still visible (#1242).

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs