[PR #2827] TUI: treat interrupted streams as clean aborts #10451

Closed
opened 2026-02-16 18:15:06 -05:00 by yindo · 0 comments
Owner

Original Pull Request: https://github.com/anomalyco/opencode/pull/2827

State: closed
Merged: No


  • Handle ESC interrupts as user aborts instead of unknown errors.
  • Detect abort signal and OpenAI “reasoning … required following item” error; store MessageAbortedError (“Request was aborted”).
  • Clean up open reasoning parts; preserve tool input; mark tools “Tool execution aborted”.
  • Add unit test and interactive scripts; typecheck passes.

Files

  • packages/opencode/src/session/prompt.ts
  • packages/opencode/test/interrupt-handling.test.ts
  • test-interrupt-*.sh
**Original Pull Request:** https://github.com/anomalyco/opencode/pull/2827 **State:** closed **Merged:** No --- - Handle ESC interrupts as user aborts instead of unknown errors. - Detect abort signal and OpenAI “reasoning … required following item” error; store MessageAbortedError (“Request was aborted”). - Clean up open reasoning parts; preserve tool input; mark tools “Tool execution aborted”. - Add unit test and interactive scripts; typecheck passes. Files - packages/opencode/src/session/prompt.ts - packages/opencode/test/interrupt-handling.test.ts - test-interrupt-*.sh
yindo added the pull-request label 2026-02-16 18:15:06 -05:00
yindo closed this issue 2026-02-16 18:15:06 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#10451