Repository navigation
fix(server): capture the checkpoint when a steer restarts a run at turn end - #289
Merged
orbitingflea merged 2 commits intoNov 24, 2026
Merged
Conversation
A steer can read a run as running, and the run's provider turn can then end before the steer commits its restart. The restarted attempt must give the run its checkpoint, and a Stop that lands before the restarted turn starts must keep the first attempt's checkpoint. Today the restarted attempt's capture is dropped, so the run ends with no checkpoint. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… checkpoint The turn-end checkpoint capture used the run id as its outbox effect id. When a late steer restarted a run whose turn had just ended, the restarted attempt's capture reused that id and the outbox dropped it, so the run ended with no checkpoint and was not offered as the latest fork point. Key the capture effect id by run attempt, at turn end and at Stop. The command id stays per run, so the capture's commit receipt and startup recovery are unchanged, and the readers added with run completion at turn end now find a run's unsettled capture by that command id, which also finds rows queued before this change. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Thread transfer impact✅ Thread transfer remains within every enforced ceiling.
Other scenariosNo All 64 scenario measurements
Baseline: unavailable · PR result: Scenario and decoded snapshot size10 historical turns, 5 command tools per turn, 878.9 KiB retained MCP result per historical turn, and a 1.05 MiB retained result in the measured turn.
Updated in place by a trusted workflow. PR artifacts are strictly validated and never executed. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Behaviour change
Behaviour change: yes, when a steer restarts a run at turn end, the run keeps the restarted attempt's checkpoint, so it is offered as the latest fork point and the next run counts changes from it. This restores fork behaviour dropped in stage 1.
Why
Capture the restarted checkpoint when a steer restarts a run at turn end and keep pingdotgg#41362 waits.
In pingdotgg#41362, if a steer awaits the adapter at turn end, 5 retries fail and the restart hits an
effect_idconflict, so it gets no checkpoint. Stage 1 dropped861311151cand48386e903dbecause pingdotgg#41362 read by run id. No upstream PR covers this.What changed
effect:checkpoint.capture:<attemptId>inRunExecutionService.tsandOrchestrator.ts. Keepcommand:effect:checkpoint.capture:<runId>per run.awaitsCheckpointCaptureandawaitLatestRunCaptureso steers, forks, and older rows wait.steerRestartCheckpoint.integration.test.ts. No upstream test files change.Tradeoffs
Blast Radius
Server orchestration only. No schema, migration, or client change.
Verification