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

forked from trevato/cs

game is down? i see not up in the dashboard and when i visit it is a a cloudf… #356

Merged opened this in answer to

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

Merged

Fixes #354: production went down because the typecheck failed, so the deploy's test step (`bun run test`, which runs `tsc --noEmit` before `bun test`) failed too. The forge's app API shows production as `failed` with "test: test exited with code 1", so the dashboard showed it as not up and the site returned the Cloudflare page.

shipped production is serving it deploy ae07c2d

opened this

Fixes #354: production went down because the typecheck failed, so the deploy's test step (bun run test, which runs tsc --noEmit before bun test) failed too. The forge's app API shows production as failed with "test: test exited with code 1", so the dashboard showed it as not up and the site returned the Cloudflare page.

Cause: #352 and #353 were merged one after the other and clashed. #352 added room tests to src/server.test.ts that import isRoomCode from ./rooms/code.ts. #353 moved room codes into the engine (src/engine/rooms.ts) and deleted src/rooms/code.ts, but didn't update that import. Each change was fine alone; together they left a test importing a file that no longer exists.

Change: src/server.test.ts now imports roomCodeFrom from ./engine/index.ts, the same place src/server.ts and src/client/main.ts get it. The check becomes expect(roomCodeFrom(room.code)).toBe(room.code), which passes only if the code is already a valid, upper-case room code, so it checks the same thing as before. This is a test-only change: the test was wrong, not the app. No app code or dependencies changed.

Not done: isRoomCode is still not exported from the engine's public entry point (src/engine/index.ts). Adding it would change the engine's surface (src/engine/surface.json), and this fix doesn't need it.

Verified: after bun install, bun run test gives a clean typecheck and 1411 passing tests, 0 failing. The server boots and / answers 200 in about 23 ms. Production should come back once this is merged; the preview for this branch is the first place to check that it deploys.

🤖 Generated with Claude Code

Closes #354

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs