Skip to content

deepseek-v4-flash on opencode-go drops connection before response (pro works on same endpoint) #40465

Closed as not planned

Description

@MyGO-Mujica

Description

deepseek-v4-flash served through the OpenCode Go provider (https://opencode.ai/zen/go/v1) is unreachable: the upstream closes the TCP connection before returning any HTTP response, causing every request to hang until OpenCode's 30s timeout fires an AbortError. The request never reaches the model.

In contrast, deepseek-v4-pro on the same endpoint, same API key, same auth responds normally (HTTP 200 with content + reasoning). This strongly indicates a server-side routing/availability issue with the flash lane on the zen/go backend, not a client config or auth problem.

Direct API probe (outside OpenCode, via Invoke-WebRequest):

Model Endpoint Result
deepseek-v4-flash https://opencode.ai/zen/go/v1/chat/completions Connection closed by remote before any HTTP response (non-stream and stream both fail)
deepseek-v4-pro https://opencode.ai/zen/go/v1/chat/completions HTTP 200, valid chat.completion with reasoning_content

OpenCode log captured during the failure (identical pattern for every flash attempt):

timestamp=... level=INFO message="stream providerID=opencode-go modelID=deepseek-v4-flash ... agent=orchestrator"
timestamp=... level=INFO message="llm runtime selected" llm.runtime=ai-sdk llm.provider=opencode-go llm.model=deepseek-v4-flash
# ~30s later:
timestamp=... level=ERROR message=process ... error=Aborted stack="AbortError: Aborted\n    at new DOMException ..."

The same session then falls back to deepseek-v4-pro or glm-5.2 on the same provider and succeeds, confirming the failure is scoped to deepseek-v4-flash.

Plugins

  • oh-my-opencode-slim
  • oc-codex-multi-auth
  • @cortexkit/opencode-magic-context@latest

OpenCode version

1.18.4.0 (OpenCode Desktop)

Steps to reproduce

  1. Configure OpenCode with the opencode-go provider and auth (OPENCODE_API_KEY).
  2. Set any agent (e.g. orchestrator) to opencode-go/deepseek-v4-flash.
  3. Send any message.
  4. Observe: the request hangs ~30s with no streamed tokens, then aborts with AbortError: Aborted. No error is surfaced from the upstream; the connection is dropped before an HTTP status is returned.

Independent reproduction (bypassing OpenCode entirely):

curl -X POST https://opencode.ai/zen/go/v1/chat/completions \
  -H "Authorization: Bearer $OPENCODE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"model":"deepseek-v4-flash","messages":[{"role":"user","content":"hi"}],"max_tokens":10,"stream":false}'
# -> connection closed by remote, no HTTP response
curl -X POST https://opencode.ai/zen/go/v1/chat/completions \
  -H "Authorization: Bearer $OPENCODE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"model":"deepseek-v4-pro","messages":[{"role":"user","content":"hi"}],"max_tokens":10,"stream":false}'
# -> HTTP 200, valid completion

Operating System

Windows 11

Terminal

Windows PowerShell 5.1

Additional context

  • Auth type: API key (OPENCODE_API_KEY), OpenCode Go plan.
  • The failure is not the same as deepseek giving up #38765 ("deepseek giving up after a few seconds"): that issue describes the model starting then stopping mid-stream. Here the connection is dropped before any byte of response, every time, consistently. No partial output, no "thinking" state — just a silent hang until timeout.
  • Possibly related to DeepSeek v4 Flash Model #40460, but that issue lacks reproduction details and template compliance. This report provides server-side isolation evidence (flash vs pro on the same endpoint).
  • deepseek-v4-pro, glm-5.2, and gpt-5.6-luna on the same opencode-go provider all work, so this is not a blanket provider outage.
  • Suggested mitigation for affected users: switch agents off deepseek-v4-flash to deepseek-v4-pro or another available model on the same provider until the flash lane is restored.

Activity

  1. github-actions commented on Aug 4, 2026

    @github-actions
    Contributor

    This issue might be a duplicate of existing issues. Please check:

  2. leirbag4 commented on Aug 4, 2026

    @leirbag4

    same here, doesn´t work

  3. ruslankonev commented on Aug 4, 2026

    @ruslankonev

    the same

  4. addisonrobertss commented on Aug 4, 2026

    @addisonrobertss

    same problem not working DEEPSEEK V4 FLASH

  5. metrofun commented on Aug 4, 2026

    @metrofun

    The isolation here points to the hosted Flash lane rather than the OpenCode client. If you have direct DeepSeek API access, you can keep using OpenCode while bypassing that lane.

    I maintain Swobu, a local compatibility gateway:

    curl -fsSL https://swobu.com/install.sh | sh
    swobu

    Add a DeepSeek target in Cockpit using your DEEPSEEK_API_KEY and deepseek-v4-flash, then point OpenCode at the local workspace:

    {
      "$schema": "https://opencode.ai/config.json",
      "model": "swobu/deepseek-v4-flash",
      "provider": {
        "swobu": {
          "npm": "@ai-sdk/openai-compatible",
          "name": "Swobu",
          "options": {
            "baseURL": "http://127.0.0.1:7926/c/dev/v1"
          },
          "models": {
            "deepseek-v4-flash": {
              "name": "DeepSeek V4 Flash"
            }
          }
        }
      }
    }

    This keeps OpenCode as the client but sends requests to your direct DeepSeek target instead of https://opencode.ai/zen/go/v1.

    It does not restore the OpenCode Go Flash lane or transfer its plan entitlement; it requires separate direct DeepSeek API access to that model.

  6. DejanGegic commented on Aug 10, 2026

    @DejanGegic

    this is the second opencode GO issue with deepseek v4 in the last 7 days. here too

  7. github-actions commented on Oct 11, 2026

    @github-actions
    Contributor

    To stay organized issues are automatically closed after 60 days of no activity. If the issue is still relevant please open a new one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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