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

A crew run interrupted by a restart twice in a row is failed with its reason, not queued a third time #11581

shipped production is serving it opened this has it
opened this

Intent: a forge stopped every 90 s no longer loops a run until its credit is gone. First third of #11560 (parked twice: both pulls spread across eight files and the heavy test/crew-interrupted.test.ts and stayed red). Start fresh from main; touch only the files below.

Done:

  • [ ] in src/crew/dispatch.ts, requeueInterrupted fails (via finishRun in src/core/runs.ts) a lapsed run that was itself queued by an interruption (its summary starts with REQUEUED_SUMMARY's words), with the summary "stopped twice by its forge restarting; not tried again", and does not queue it again
  • [x] a run interrupted once is still cancelled and queued again exactly as today
  • [x] new test/crew-stopped-twice.test.ts, in-process with createApp and a temp dir and no servers or crew loop: one interruption → queued again; two in a row → failed with that summary, nothing queued; each fails without the change
  • [x] the new test file joins scripts/gate.ts in the same commit if the gate does not find it by itself
  • [x] bun x tsc --noEmit and bun test test/crew-stopped-twice.test.ts pass in the sandbox before the push

Files: src/crew/dispatch.ts, test/crew-stopped-twice.test.ts (new), possibly scripts/gate.ts. Risks: do not edit test/crew-interrupted.test.ts, the web or docs here. The earlier branch scout/11560-… at 769af5d64133 may be read for ideas. Suggested brief: scout.

commented

Reviewed pull #11585 at its head: ticked a run interrupted once is still cancelled and queued again exactly as today; new test/crew-stopped-twice.test.ts, in-process with createApp and a temp dir and no servers or crew loop: one interruption → queued again; two in a row → failed with that summary, nothing queued; each fails without the change; the new test file joins scripts/gate.ts in the same commit if the gate does not find it by itself; bun x tsc --noEmit and bun test test/crew-stopped-twice.test.ts pass in the sandbox before the push.

commented

Left open after pull #11585 landed: 1 unticked item remains (in src/crew/dispatch.ts, requeueInterrupted fails (via finishRun in src/core/runs.ts) a lapsed run that was itself queued by an interruption (its summary starts with REQUEUED_SUMMARY's words), with the summary "stopped twice by its forge restarting; not tried again", and does not queue it again). The planner files each as its own issue and closes this one; a person may close it, tick what is done, or say what is left. Until then the crew does not pick it again.

commented

Already done on main in f21b12668: requeueInterrupted in src/crew/dispatch.ts fails a lapsed run whose summary starts with REQUEUED_SUMMARY via finishRun with STOPPED_TWICE and does not requeue it. Closing, nothing left.

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs