Skip to content

Make TUI turn interrupts nonblocking - #35000

Merged
copyberry[bot] merged 1 commit into
mainfrom
copyberry/codex-internal-to-codex-oss/9ada247a739e2e0a63b425f75ebd6d054167d825
Jul 23, 2026
Merged

Make TUI turn interrupts nonblocking#35000
copyberry[bot] merged 1 commit into
mainfrom
copyberry/codex-internal-to-codex-oss/9ada247a739e2e0a63b425f75ebd6d054167d825

Conversation

@copyberry

@copyberry copyberry Bot commented Jul 23, 2026

Copy link
Copy Markdown

Make TUI turn interrupts nonblocking

What changed

  • Dispatch app-server turn interrupts in the background so the TUI can keep
    processing thread events while an interrupt is pending.
  • Coalesce repeated interrupt requests for the same active turn and clear the
    pending state when the turn completes or the thread closes.
  • Preserve the retry for stale active-turn IDs, surface interrupt failures as
    warning notifications instead of exiting the TUI, and reset backtrack state
    whenever an interrupt is handled.

Testing

  • Add an app-server integration test covering nonblocking event handling,
    repeated-request coalescing, and pending-state cleanup.
  • Verify that interrupting without an active turn clears backtrack state.

## What changed

- Dispatch app-server turn interrupts in the background so the TUI can keep
  processing thread events while an interrupt is pending.
- Coalesce repeated interrupt requests for the same active turn and clear the
  pending state when the turn completes or the thread closes.
- Preserve the retry for stale active-turn IDs, surface interrupt failures as
  warning notifications instead of exiting the TUI, and reset backtrack state
  whenever an interrupt is handled.

## Testing

- Add an app-server integration test covering nonblocking event handling,
  repeated-request coalescing, and pending-state cleanup.
- Verify that interrupting without an active turn clears backtrack state.

GitOrigin-RevId: 9ada247a739e2e0a63b425f75ebd6d054167d825
@copyberry
copyberry Bot force-pushed the copyberry/codex-internal-to-codex-oss/9ada247a739e2e0a63b425f75ebd6d054167d825 branch from ef4ceec to 62ba648 Compare July 23, 2026 19:58
@copyberry
copyberry Bot merged commit 62ba648 into main Jul 23, 2026
19 of 32 checks passed
@copyberry
copyberry Bot deleted the copyberry/codex-internal-to-codex-oss/9ada247a739e2e0a63b425f75ebd6d054167d825 branch July 23, 2026 19:59
@github-actions github-actions Bot locked and limited conversation to collaborators Jul 23, 2026
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.

10 participants