Skip to content

Preserve in-flight state when restoring thread input - #33203

Merged
copyberry[bot] merged 1 commit into
mainfrom
copyberry/codex-internal-to-codex-oss/f4e8b2bdf065ef6c6644b7f0ea9cf32c8a9af619
Jul 15, 2026
Merged

Preserve in-flight state when restoring thread input#33203
copyberry[bot] merged 1 commit into
mainfrom
copyberry/codex-internal-to-codex-oss/f4e8b2bdf065ef6c6644b7f0ea9cf32c8a9af619

Conversation

@copyberry

@copyberry copyberry Bot commented Jul 15, 2026

Copy link
Copy Markdown

Preserve in-flight state when restoring thread input

What changed

  • Add an explicit restore mode for thread input snapshots and use it when replaying thread snapshots.
  • Preserve the pending-steer interrupt flag alongside running-turn and queued-input state when restoring an in-flight turn.
  • When in-flight state is not preserved, clear stale running flags and move pending steers ahead of already queued follow-ups while retaining their history records.

Testing

  • Expand TUI tests to cover both restoration modes, including sleep-inhibitor state, pending-steer ordering, history records, and queued submission.

## What changed

- Add an explicit restore mode for thread input snapshots and use it when replaying thread snapshots.
- Preserve the pending-steer interrupt flag alongside running-turn and queued-input state when restoring an in-flight turn.
- When in-flight state is not preserved, clear stale running flags and move pending steers ahead of already queued follow-ups while retaining their history records.

## Testing

- Expand TUI tests to cover both restoration modes, including sleep-inhibitor state, pending-steer ordering, history records, and queued submission.

GitOrigin-RevId: f4e8b2bdf065ef6c6644b7f0ea9cf32c8a9af619
@copyberry
copyberry Bot force-pushed the copyberry/codex-internal-to-codex-oss/f4e8b2bdf065ef6c6644b7f0ea9cf32c8a9af619 branch from 34a35ea to 77a3f4e Compare July 15, 2026 01:48
@copyberry
copyberry Bot merged commit 77a3f4e into main Jul 15, 2026
14 of 32 checks passed
@copyberry
copyberry Bot deleted the copyberry/codex-internal-to-codex-oss/f4e8b2bdf065ef6c6644b7f0ea9cf32c8a9af619 branch July 15, 2026 01:49
@github-actions github-actions Bot locked and limited conversation to collaborators Jul 15, 2026
@98woo
98woo temporarily deployed to issue-triage July 15, 2026 02:01 — with GitHub Actions Inactive
@98woo
98woo temporarily deployed to issue-triage July 15, 2026 02:01 — with GitHub Actions Inactive
@98woo
98woo temporarily deployed to issue-triage July 15, 2026 02:01 — with GitHub Actions Inactive
@98woo
98woo temporarily deployed to issue-triage July 15, 2026 02:02 — with GitHub Actions Inactive
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants