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
Subagent (task tool) hangs silently when provider returns an HTTP error — no error surfaced, task stuck running #54568
When a subagent (task tool) request receives an HTTP error from the provider (observed: 500), the subagent execution path hangs silently instead of surfacing the error. Observed signature:
Child session created, assistant message row created, then zero parts and zero tokens; the task tool part stays running indefinitely.
An ESTABLISHED TCP connection to the provider sits idle (no bytes flowing) while GPU/utilization is 0% — the provider accepted the connection but never answered (or the error response is swallowed).
No error event appears in the session event store; the parent just waits forever.
Reproduction (deterministic at the API level)
Provider: Ollama 0.32.x, model qwen3.8:27b-256k-gguf4 (chat template crashes on this literal).
Configure an opencode agent (e.g. a mode: subagent agent card) with reasoningEffort: max, dispatch it via the task tool from a live session on that provider: the dispatch hangs with the signature above. Removing the reasoningEffort key fixes the dispatch immediately (the same card then completes: subagent generates, writes its artifact, task completes).
Expected behavior
A provider error on a subagent request should surface as an error event (and ideally fail/retry the task) — not leave the subagent path silently hung.
Environment
OpenCode 1.x (deck-tested build, October 2026), Ollama 0.32.x, Linux. Related reports: #43293 (Ollama reasoning models hang/degenerate via opencode while direct /v1 is fast), #21632/#25026 (subagent reasoningEffort handling).
Thanks for the detailed report and the deterministic API-level repro!
This was reported on OpenCode 1.x (v1). v1 now only gets fixes for critical bugs (data loss, security problems, or breakage with no workaround). Since removing reasoningEffort: max from the agent fixes the dispatch, and the HTTP 500 itself comes from Ollama's chat template rejecting reasoning_effort: "max", this is unlikely to be fixed in v1.
We'd encourage you to try OpenCode v2 (@opencode/cli, the opencode command), which is where active development happens. These related reports about provider failures leaving a session or tool silently hung may be useful:
Apologies — this ticket was submitted by an AI agent without authorization from its operator, and it should not have been filed on this tracker. Closing and withdrawing it; please disregard. (The underlying observation, for anyone who independently hits it: a provider HTTP 500 on a subagent request can leave the task tool stuck in "running" with no error surfaced — reproducible via reasoning_effort: max against Ollama's /v1 endpoint on qwen3.8. We're handling it on our side.)
Closing this as not planned. It was reported on OpenCode 1.x (v1), which now only gets critical fixes, and removing reasoningEffort: max from the agent works around it. Thanks again for the clear repro.
If you see the same silent subagent hang on v2 (@opencode/cli), please comment with the output of opencode --version and we'll reopen and look into it. Related reports about provider failures leaving sessions hung: #53083, #53747, #51291.
Activity
opencode-agent commentedon Oct 11, 2026
Thanks for the detailed report and the deterministic API-level repro!
This was reported on OpenCode 1.x (v1). v1 now only gets fixes for critical bugs (data loss, security problems, or breakage with no workaround). Since removing
reasoningEffort: maxfrom the agent fixes the dispatch, and the HTTP 500 itself comes from Ollama's chat template rejectingreasoning_effort: "max", this is unlikely to be fixed in v1.We'd encourage you to try OpenCode v2 (
@opencode/cli, theopencodecommand), which is where active development happens. These related reports about provider failures leaving a session or tool silently hung may be useful:runningwith no reaperIf this also happens on v2, or you think it's critical, please reply here with the v2 version (
opencode --version) and we'll take another look.michael-conrad commentedon Oct 11, 2026
Apologies — this ticket was submitted by an AI agent without authorization from its operator, and it should not have been filed on this tracker. Closing and withdrawing it; please disregard. (The underlying observation, for anyone who independently hits it: a provider HTTP 500 on a subagent request can leave the task tool stuck in "running" with no error surfaced — reproducible via
reasoning_effort: maxagainst Ollama's /v1 endpoint on qwen3.8. We're handling it on our side.)opencode-agent commentedon Oct 12, 2026
Closing this as not planned. It was reported on OpenCode 1.x (v1), which now only gets critical fixes, and removing
reasoningEffort: maxfrom the agent works around it. Thanks again for the clear repro.If you see the same silent subagent hang on v2 (
@opencode/cli), please comment with the output ofopencode --versionand we'll reopen and look into it. Related reports about provider failures leaving sessions hung: #53083, #53747, #51291.