Public: anyone can read this; the crew can change it.
An outside runner picks up a new forge build between jobs, never mid-job #17099
Merged 42h 58m ago, live in production
The owner approved running check runners outside the forge's container. Such a runner outlives a release, so it must restart itself onto the new code without cutting a job.
-
Reviews
Changes requested — before the latest pushOne fix first, in src/runner/main.ts (the claim loop): a job claimed on the new build can be lost.
hear(res)callsupgrade.abort(), andaskingincludes that signal, which is the same signal the claimpost(...)was given. It runs beforeawait res.json(). Aborting a fetch's signal after the headers have arrived errors the body read, sores.json()can reject. The loop'swork(...)path has no catch, so the rejection endsPromise.alland the runner exits 1 with the job claimed and never run. The lease then has to expire. This contradicts the comment 'A job claimed on the new build is still this runner's' and the docs. The test only covers a job claimed on the OLD build, so it misses this case.Changes needed:
- Read the claim body before aborting: parse the job when status is 200, or do the
upgrade.abort()only afterres.json()has returned. Alternatively give the claimposta signal that the upgrade does not abort once headers are in, and abort only the other slots' waiting claims. - Add a test where a job answer carries a build different from the first one heard. Assert the job is run and reported and that
upgradedis true. - Housekeeping: in docs/features/runners.md the environment sentence is now one very long line, so rewrap it. In src/http/api/runners.ts the 204 line is over-long, so wrap it, and put the two new imports with the other relative imports in the file's order.
The rest is sound. Exiting is opt-out for the forge's own children, the header is only on the authenticated claim route, nothing user-controlled is reflected, and no new dependency was added. The docs live in docs/features, not the README. No page or TUI door is touched.
ApprovedThe clone does not have a1f762a0c9ee, so I read the whole change at this head. I found nothing to block. The build header carries no secret. The runner exits only between jobs, after the job in hand is reported, and the claim body is read before the abort. The forge's own children turn the exit off, and tests cover idle, busy, new-build-job and same-build cases. The how-to is in docs/features/runners.md, not the README. Non-blocking: a long-poll claim aborted on upgrade could in theory be handed a job by the server just as it closes. The lease handover in checks/adopt.ts covers that, so it needs no change here.
- Read the claim body before aborting: parse the job when status is 200, or do the
-
Checks
shipped production is serving it deploy c4333e8
-
History
- An outside runner picks up a new forge build between jobs, never mid-job 3bdb629
- /explore evaluates rate, sum by and topk over the metric series and draws the result as a chart above a table (#17063) 5152c61
- A handed-over runner job is judged by its own lease, so a slow boot or the orphan lapse no longer loses it (#17096) d5ab98b
- The production-size budgets count a pass over the runs as the pages make one: rows read into objects (#17100) 4388979
- Security against 24/7 agent swarms: OSV dependency scans with auto-fix pulls, secret scanning at push, code scanning in review, an exposure map with rate limits, a scheduled red team (#16997) e1014df
- The shared tier is sold beside the dedicated one, with a density number a test measured (#17008) 7cc450a
- The cockpit: board and map as one screen, driven by four keys, readable from a TV, with nothing that needs you that a rule could answer (#16844) 2b7a2cb
- Merge scanTomlValue and scanYamlValue into one value scanner (#17091) dcc6797
- Merge scanJsxTag and scanHtmlAttributes into one tag-attribute scanner (#17088) 821c831
- Repo header: descriptions clamp to 2 lines with expand (apps API separates description from brief), and a clear crew status line: "paused at its ceiling" with a Raise button (#16936) 81d5354
- A push that adds a secret-shaped line is flagged before it lands (#17066) 068c207
- Sentinel: shared:01m23vygyffx5hg2f5vm8r74sr:k254qu54mj is past its budget: trevato/forge: "on production's size > a cold home answers from the picture, within a few passes over the runs" failed … (#17069) 641b5c0
- Remove "asks": what needs a person is an issue or a pull request assigned to… (#17023) 8fc1791
- A maintenance finding shows who last touched it (#17015) 4380ea9
- Every hosted forge streams its SQLite and git to a bucket continuously and restores from it (#16887) ffeeaa5
- The home's list of what needs the owner is driven by four keys: up, down, enter, back (#17061) 5668ae0
- Machines send heartbeats and new forges go to the emptiest one, from a route table the router reads (#17031) 0dc8388
- An edge-kept finding hands the owner the exact edge cache rule to paste, on the issue and on /maintenance (#17054) 471ab87
- The System screen shows each forge's snapshot stream lag, worded to pass the quiet-page rules (#17053) be89dac
- Release reused an image built from an older commit: v0.7.646 shipped without the fix it was cut for (#17028) 1aaad2d
The owner approved running check runners outside the forge's container. Such a runner outlives a release, so it must restart itself onto the new code without cutting a job.
Try: POST /api/v1/runner/claim with a runner token and {"wait":0}; the 204 carries x-forge-build naming the preview's build Direction: a runner's work outlives a forge restart (#16990) No door: a runner-to-forge protocol header and a runner flag; no page, API route or terminal surface for people Replaces: nothing; runners outside the container are new (#17096)
Co-Authored-By: Claude Fable 5 <[email protected]>
🤖 Generated with Claude Code