Skip to content

Desktop stuck in "thinking" mode - sidecar stream never completes (v1.17.18, Windows) #36370

Description

@eunjinue

Description

Body:

Environment

  • OS: Windows 10/11
  • OpenCode Desktop: v1.17.18 (Electron, packaged)
  • Node.js: (bundled with Electron)

Description

When sending any message in OpenCode Desktop, the app enters a permanent "thinking" state and never returns a response. This happens with all models — built-in free models (deepseek-v4-flash-free, hy3-free, mimo-v2.5-free) and custom providers (Agnes, Sensenova).

Reproduction Steps

  1. Launch OpenCode Desktop
  2. Select any model (free or custom)
  3. Send a message (e.g., "你好")
  4. App shows "thinking" indicator indefinitely

Log Analysis

Sidecar starts and becomes ready

sidecar connection started { url: 'http://127.0.0.1:XXXXX' }
spawning sidecar { url: 'http://127.0.0.1:XXXXX' }
server ready { url: 'http://127.0.0.1:XXXXX' }

Stream starts but never completes

From ~/.local/share/opencode/log/opencode.log:
message=stream providerID=opencode modelID=hy3-free session.id=ses_XXX small=false agent=build mode=primary
message="llm runtime selected" llm.runtime=ai-sdk llm.provider=opencode llm.model=hy3-free
After this, no further log entries — the stream hangs silently.

Sidecar exits after ~6 minutes

From Electron logs:
warn (utility) sidecar exited { code: 0 }

Persistent npm warning

WARN background dependency install failed
dir="C:\Users<user>.config\opencode"
error="Cause(Fail(NpmInstallFailedError (cause: @opencode-ai/plugin: No matching version found for @opencode-ai/plugin@local.)))"

Git lock file conflict

WARN failed to add snapshot files
exitCode=128
stderr="fatal: Unable to create '.../snapshot/global/.../index.lock': File exists.
Another git process seems to be running in this repository, or the lock file may be stale"

What I've Tried

  1. Restarted OpenCode — same issue
  2. Cleared all cache/session data (AppData\Roaming\ai.opencode.desktop, ~/.local/share/opencode, ~/.cache/opencode) — same issue
  3. Reinstalled OpenCode completely — same issue
  4. Verified API works directly — tested https://opencode.ai/zen/v1/chat/completions via PowerShell, returns valid responses
  5. Checked proxy — v2rayN/xray running on 127.0.0.1:10808, but no proxy env vars are set (HTTP_PROXY, HTTPS_PROXY all empty)

Hypothesis

The sidecar's Node.js process may be:

  1. Hanging on the @opencode-ai/plugin@local npm dependency install (blocking the event loop?)
  2. Stuck waiting for a response that never arrives due to network/proxy configuration
  3. The useEnvProxy()http.setGlobalProxyFromEnv() call may be interfering with outgoing requests even when no proxy env vars are set

Additional Info

  • The @opencode-ai/plugin@local error appears every time the sidecar initializes
  • Sidecar process (PID) is alive and listening on its port, but the stream never completes
  • No firewall/antivirus blocking detected

Plugins

No response

OpenCode version

No response

Steps to reproduce

No response

Screenshot and/or share link

No response

Operating System

No response

Terminal

No response

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions