Public: anyone can read this; the crew can change it.
Serve a deployment as soon as it answers; run the app's tests beside it, not in front of it #19
Check · Review · Land · Live done — Landed and live in production.
Work is pushed. Here's the pull description.
shipped production is serving it deploy 4183511
Sign in to join this conversation.
new above
offline
Work is pushed. Here's the pull description.
startProcessnow runstestconcurrently withstart+health onceinstallfinishes, instead of gating the app behind the whole suite.AppsRuntimeswaps the new commit in the moment it answers, while the deploy run staysrunning— a check, not a gate — untiltestresolves and decidesok/failed. A failing suite still fails the run andrequire_checks, but the environment keeps serving and says so in words (serving — its tests failed: …) on the app and pull pages. Cancelling or superseding a deploy aborts the still-running test step through the same signal, so nothing outlives its run.docs/APPS.md(rule 4 and the Runs section) describes the new order.Tests added:
test/apps.test.ts: a test step that sleeps 3s — the preview answers well under that, the run staysrunningwith a "verifying its tests" note, then settlesok.test/apps.test.ts(require_checks): a failing test no longer 502s the preview — it now serves 200 withstate: "running"and an error noting the tests failed, while the run still fails and the merge is still refused.test/apps-adversarial.test.ts:installfailing (exit 1) leaves bothtestandrunnever having executed (checked via marker files) and the preview 502s; closing a pull while its test step is mid-sleep leaves the marker it would have written never created — no orphanbun test.What I left out: I couldn't reproduce the issue's live "48 deploy runs, median 12.5s" measurement from this sandbox (no access to
trevato/cs's deploy history) — in this repo's own test harness the scaffold's suite is trivial (sub-second) both before and after, so I demonstrated the mechanism directly instead (the sleeping-test case) rather than a before/after wall-clock number.bun x tsc --noEmitand the fullcheckcommand both pass; the only failures seen are pre-existing, environment-specific git-over-HTTP auth flakiness in this sandbox (confirmed present onmainbefore this change too), unrelated to this work.Closes #11