anomalyco / anomalyco/opencode

Network interruption corrupts conversation state: reasoning encrypted_content was not issued to this caller

Open
#49,083 2 comments 1 reaction 1 assignee View on GitHub

@jlongster is already working on this.

Since Sep 15, 2026.

Dominant language
TypeScript
Stars
209k
Forks
27.5k
PR merge metrics
PR metrics pending

Description

When a temporary network interruption occurs during a stream/response, subsequent messages sent in the same conversation thread fail persistently with an upstream provider error. The thread becomes permanently unusable.

OpenCode returned an error: Error from provider (Console): Upstream request failed: [invalid_request_error] reasoning encrypted_content was not issued to this caller

Steps to Reproduce
Start an active chat/session that uses reasoning/thinking content from the upstream provider.

Trigger an interrupted connection or drop network connectivity while a response is being generated/streamed.

Once reconnected, attempt to continue the conversation by sending a new message.

Expected Behavior
The client should either:

Safely prune or omit corrupted/unverified incomplete reasoning payloads from the message history before re-sending upstream.

Offer an option to retry the interrupted turn without sending invalid cached tokens/signatures.

Actual Behavior
The previous turn saves an incomplete or invalid encrypted_content token in the context history. All subsequent calls pass this bad state back to the provider, causing the upstream API to reject the request and completely locking the user out of the thread.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.