[PR #3987] Fix: Display Claude Code rate limit errors in UI #10835

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

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

State: closed
Merged: No


Problem

When Claude Code returns rate limit errors, OpenCode shows endless loading instead of displaying the error message.

Root Cause

The onError handler in streamText was only logging errors but not re-throwing them, preventing errors from being caught and displayed in the UI.

Fix

Added throw error in the onError handler to properly propagate errors to the UI error handling.

**Original Pull Request:** https://github.com/anomalyco/opencode/pull/3987 **State:** closed **Merged:** No --- ## Problem When Claude Code returns rate limit errors, OpenCode shows endless loading instead of displaying the error message. ## Root Cause The `onError` handler in `streamText` was only logging errors but not re-throwing them, preventing errors from being caught and displayed in the UI. ## Fix Added `throw error` in the `onError` handler to properly propagate errors to the UI error handling.
yindo added the pull-request label 2026-02-16 18:15:35 -05:00
yindo closed this issue 2026-02-16 18:15:35 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#10835