You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Silent failure: opencode provider returns 500 errors but client drops response without showing error #38644
When using opencode/big-pickle (the built-in opencode provider), intermittent AI_APICallError: Internal server error (500) responses cause the agent to silently stop responding. The user sees the spinner ("thinking...") for a while, then the flow cuts with no output, no error message, and no indication anything went wrong.
From the logs, I can see the client retries internally (multiple stream error entries followed by new stream attempts), but after exhausting retries it silently drops the response instead of surfacing the error to the user.
Log evidence
Here's a sample from ~/.local/share/opencode/log/opencode.log:
Additional quantitative evidence from a long-running Linux setup (Ubuntu 24.04 / WSL2, opencode 1.18.16, provider opencode, model big-pickle, no custom provider options).
Aggregating ~/.local/share/opencode/log/opencode.log, AI_APICallError: Internal server error from providerID=opencode modelID=big-pickle occurred 409 times.
By day (UTC):
Date
Count
2026-07-22
34
2026-07-23
64
2026-07-24
172
2026-07-27
130
2026-07-28
4
2026-08-11
1
By agent (main path, small=false):
build: 241
plan: 135
compaction: 18 (not mentioned in the original report — /compact also fails, leaving sessions to grow unbounded)
explore: 6
general: 4
Behavior matches the report exactly: 3-6 stream error entries followed by new stream retries per message; when retries are exhausted the response is silently dropped with no error surfaced to the user. It correlates with degraded backend periods (heavy on Jul 24 and Jul 27), so it appears to be server-side on the opencode provider, and it is still occurring as of 2026-08-11 (opencode 1.18.16).
The compaction agent being affected (18 occurrences) is an additional data point: failed compactions never complete and the session context keeps growing. Worth tracking alongside the silent-drop behavior.
Adding a fresh data point: beyond AI_APICallError: Internal server error (my earlier quantitative comment), I’m now seeing providerID=opencode modelID=big-pickle fail with socket-level disconnects that also result in user-visible silent drops.
Last 5 minutes (UTC)
From ~/.local/share/opencode/log/opencode.log (OpenCode 1.18.18, Linux/WSL2):
stream error socket closed for big-pickle: 2
error=Aborted: 6
Verbatim examples:
timestamp=2026-08-16T23:51:13.948Z level=ERROR run=042c53b4 message="stream error" providerID=opencode modelID=big-pickle session.id=ses_ff3194081ffebphxmz8WESfcYH small=false agent=build mode=primary error.error="AI_APICallError: Cannot connect to API: The socket connection was closed unexpectedly ..."
timestamp=2026-08-16T23:53:54.387Z level=ERROR run=042c53b4 message="stream error" providerID=opencode modelID=big-pickle session.id=ses_ff3194081ffebphxmz8WESfcYH small=false agent=compaction mode=primary error.error="AI_APICallError: Cannot connect to API: The socket connection was closed unexpectedly ..."
This aligns with #32366 (UI stuck/silent after stream error). I opened a dedicated issue for this failure mode as well and cross-linked it.
Update (v1.18.30, 2026-09-12) — Internal-server-error class: no recurrence on the current build
Same environment as my evidence (Ubuntu 24.04/WSL2, opencode/big-pickle, no custom provider options). Today's full-day log:
AI_APICallError: Internal server error (stream): 0 (was 172 on peak day 2026-07-24, ~409 cumulative per my 2026-08-11 evidence, then 890 total stream error across log history per my 2026-09-02 analysis).
Proposal: given zero recurrence on v1.18.30 plus the 1.18.27 timeout default, this class looks addressed and/or backend-stabilized. Suggest closing, or folding any remaining verification into #42950 (canonical for the stream-failure family). I'll report back if the 500s resurface.
Activity
github-actions commentedon Jul 24, 2026
This issue might be a duplicate of existing issues. Please check:
aentrepreneur commentedon Aug 11, 2026
Additional quantitative evidence from a long-running Linux setup (Ubuntu 24.04 / WSL2, opencode 1.18.16, provider
opencode, modelbig-pickle, no custom provider options).Aggregating
~/.local/share/opencode/log/opencode.log,AI_APICallError: Internal server errorfromproviderID=opencode modelID=big-pickleoccurred 409 times.By day (UTC):
By agent (main path,
small=false):/compactalso fails, leaving sessions to grow unbounded)Behavior matches the report exactly: 3-6
stream errorentries followed by newstreamretries per message; when retries are exhausted the response is silently dropped with no error surfaced to the user. It correlates with degraded backend periods (heavy on Jul 24 and Jul 27), so it appears to be server-side on the opencode provider, and it is still occurring as of 2026-08-11 (opencode 1.18.16).The
compactionagent being affected (18 occurrences) is an additional data point: failed compactions never complete and the session context keeps growing. Worth tracking alongside the silent-drop behavior.aentrepreneur commentedon Aug 16, 2026
Adding a fresh data point: beyond
AI_APICallError: Internal server error(my earlier quantitative comment), I’m now seeingproviderID=opencode modelID=big-picklefail with socket-level disconnects that also result in user-visible silent drops.Last 5 minutes (UTC)
From
~/.local/share/opencode/log/opencode.log(OpenCode 1.18.18, Linux/WSL2):stream errorsocket closed for big-pickle: 2error=Aborted: 6Verbatim examples:
This aligns with #32366 (UI stuck/silent after stream error). I opened a dedicated issue for this failure mode as well and cross-linked it.
aentrepreneur commentedon Sep 13, 2026
Update (v1.18.30, 2026-09-12) — Internal-server-error class: no recurrence on the current build
Same environment as my evidence (Ubuntu 24.04/WSL2,
opencode/big-pickle, no custom provider options). Today's full-day log:AI_APICallError: Internal server error(stream): 0 (was 172 on peak day 2026-07-24, ~409 cumulative per my 2026-08-11 evidence, then 890 totalstream erroracross log history per my 2026-09-02 analysis).message="stream error"today: 0.v1.18.27now defaults streamed chunk timeouts to five minutes (directly addresses the silent-stall variant of SSE stream silently dropped mid-response hangs session/subagents forever — chunkTimeout has no default on the openai path #37580 that this issue overlapped with).Proposal: given zero recurrence on v1.18.30 plus the 1.18.27 timeout default, this class looks addressed and/or backend-stabilized. Suggest closing, or folding any remaining verification into #42950 (canonical for the stream-failure family). I'll report back if the 500s resurface.