Skip to content

opencode-go: GLM-5.3-Flash long streams cut off without finish_reason, repeated retries #50146

Closed as not planned

Description

@spkrninv

Description

When using OpenCode Go with opencode-go/glm-5.3-flash, long-running streams are cut mid-generation. The SSE stream ends with HTTP 200 but no finish_reason, so opencode shows:

⚠ Retry due · attempt N · OpenAI Chat stream ended without finish_reason

and automatically retries (observed up to attempt 4). This happens on nearly every long request. The same client on the same network does not show this with other providers, and the connection is direct (no VPN/proxy), so it looks like the Go gateway or its edge is cutting long-lived streams.

Impact: retries eventually succeed, but long tasks gain several minutes of wall time and each attempt re-bills tokens.

Example request configuration from the TUI stats page (shown to illustrate the endpoint, not necessarily the failing request itself):

  • Endpoint: /inference/go/openai/v1/chat/completions (protocol openai-chat, product go, provider OpenCode Go)
  • HTTP 200, streaming: yes

Observed cuts from the TUI during a single Build turn with GLM-5.3-Flash: Retry due · attempt 2/3/4 · OpenAI Chat stream ended without finish_reason, with streams running ~1m50s to ~12m27s at ~24–34 tok/s before being cut.

Plugins

None

OpenCode version

2.0.10

Steps to reproduce

  1. Connect OpenCode Go and select opencode-go/glm-5.3-flash (reasoning effort max observed on affected runs)
  2. Run a long Build task that generates for several minutes
  3. Watch for ⚠ Retry due · attempt N · OpenAI Chat stream ended without finish_reason

Screenshot and/or share link

No share link yet; happy to run /share and post it on request.

Operating System

Ubuntu 24.04 (Linux 6.14.0-29-generic, x86_64)

Terminal

xterm-256color (truecolor)

Activity

  1. spkrninv commented on Sep 20, 2026

    @spkrninv
    Author
    Image Image
  2. spkrninv commented on Sep 20, 2026

    @spkrninv
    Author

    For context on the screenshots above: the first shows a single Retry due · attempt 2 after a 12m27s stream at 34.1 tok/s; the second shows one Build turn with repeated Retry due banners at attempts 2–4, with streams cut between ~1m50s and ~10m38s at ~24 tok/s. A /share link with the failing request traces will follow.

  3. neriousy commented on Oct 21, 2026

    @neriousy
    Member

    Thanks for the report. This is about how the model itself behaves when served through OpenCode Go (repeating itself, broken tool calls, speed, or rejecting large requests), not a bug in the OpenCode app. We pass these reports to our upstream providers. Starting a new session or running /compact usually helps with loops and oversized-request errors. Closing this to keep the tracker focused; the main discussion is in #50206.

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

Metadata

Metadata

Assignees

No one assigned

    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