anomalyco / anomalyco/opencode
[BUG] Incorrect handling of network errors causes the session to freeze indefinitely
@kitlangton is already working on this.
Since Aug 12, 2026.
- Dominant language
- TypeScript
- Stars
- 209k
- Forks
- 27.5k
- PR merge metrics
- PR metrics pending
Description
Description
The current version (and all previous versions of OpenCode) does not handle network errors properly, which makes it impossible to use the software effectively.
To be honest, I wholeheartedly hate whoever wrote the network error-handling code for OpenCode. It's a terrible piece of work, and I only continue to use it, albeit with some difficulty, because of its plugin ecosystem. I REALLY hope this gets fixed, because I don't understand how anyone could have designed a system that doesn’t take into account real-world problems, where the network isn't always stable.
I could submit a pull request, but the list of one thousand open PRs doesn’t give me any reason to be optimistic that my changes will be accepted. Not to mention the developers’ approach of closing bugs without fixing them simply because there hasn’t been any activity, even though the bug EXISTS. And this bug is so critical that it makes even minimally normal operation simply impossible.
Plugins
none, replayable without any plugins
OpenCode version
1.18.16
Steps to reproduce
- Start a long-running job with heavy subagents
- Your network packet was dropped/some other network error occurred
- In the best-case scenario, your random subagent stops and returns an empty result; in the worst-case scenario, it freezes permanently, crashing your ENTIRE session - either without any error messages at all or with an "unknown certificate verification error" that doesn't even correspond to an actual error. And you can't even force subagent to stop, since the developers figured that absolutely no one would ever need this feature.
- Enjoy your lost cache, your paused job, and the need to manually resume your ENTIRE job.
Screenshot and/or share link
Operating System
Windows 10
Terminal
Windows Terminal
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.