Skip to content
Source
Sign inSign up
pingdotgg/t3code

fix(server): keep interrupted threads resumable after restarts #10421

Mergedmaria-rcksmerged 2 commits intomain fromrefs/pull/10421/headmerged by maria-rcks View on GitHub

maria-rckscommented

restart and update recovery could mark active threads failed when the provider directory held an older turn id; codex resume could also fail while decoding historical errors from another provider version. recovery now uses orchestration's active turn, and codex validates only the resume metadata it consumes. excludeTurns trims the response while preserving the model's saved context; the request interface no longer needs a generic method or test cast.

verified 204 scoped tests, server typecheck, lint, and formatting on the final change. both persisted restart/update regressions fail on the original guards and pass here.

additional end-to-end checks with real codex:

  • desktop-mode restart during a blocked shell command recalled a key and number from an earlier turn, wrote their exact value, read it separately, and finished ready.
  • web-mode update recovery used the real preparation hook with automatic continuation disabled; the marked thread recalled its earlier key and number, retained its provider thread id, and cleared its update marker.
  • a second interruption of that same remote thread using sigkill recovered the original values again and finished ready.
  • an unmarked thread with continuation disabled stayed interrupted; an explicitly stopped thread stayed stopped; a completed thread kept its original timestamp and message count across subsequent restarts.

verification limits: native electron quit/relaunch and the update package installer were not exercised. the web client intermittently retained "syncing messages" after reload and completion; sending and completing the follow-up worked, but the indicator's cause remains unverified and is outside this server fix.

desktop restart preserves the earlier verification key and number

remote update preserves the earlier verification key and number

model: gpt-6-astra. harness: codex.

    1. Bugbot is paused — on-demand spend limit reached

      Bugbot uses usage-based billing for this team and has hit its on-demand spend limit.

      A team admin can raise the spend limit in the Cursor dashboard, or wait for the next billing cycle to continue.

    2. github-actions[bot](GitHub profile, opens in a new tab) added labelsvouch:trusted

    3. macroscopeapp[bot](GitHub profile, opens in a new tab)commented

      Approvability

      Verdict: Would Approve

      Macroscope's review found this PR approvable — This is a localized server bug fix that preserves interrupted provider work across restarts and makes Codex resume tolerant of unrelated historical payloads. Existing continuation remains gated by the prior opt-in or update-marking flows, with focused tests covering the changed recovery cases.

      Not approved because:

      • Monthly spending limit reached (workspace setting). Approvability relies on correctness review in order to determine eligibility
      Review your spending limits in [Billing settings](https://app.macroscope.com/pingdotgg/settings/billing). You can add or adjust custom eligibility rules. [Learn more](https://docs.macroscope.com/approvability#example-custom-eligibility-rules).
    4. Bugbot is paused — on-demand spend limit reached

      Bugbot uses usage-based billing for this team and has hit its on-demand spend limit.

      A team admin can raise the spend limit in the Cursor dashboard, or wait for the next billing cycle to continue.

    5. maria-rcks merged this1abc717

    6. maria-rcks closed this

Sign in to join this conversation.