anomalyco / anomalyco/opencode
OpenCode desktop v1.18.10 - V8 OOM 'Zone Allocation failed' when opening project
@Brendonovich is already working on this.
Since Jul 31, 2026.
- Dominant language
- TypeScript
- Stars
- 209k
- Forks
- 27.5k
- PR merge metrics
- PR metrics pending
Description
Title: OpenCode desktop v1.18.10 — V8 OOM "Zone Allocation failed" when opening project (server OOM, renderer "Failed to load sessions")
Environment
- App: OpenCode Desktop v1.18.10 (darwin)
- OS: macOS
- Repo: a local code repository (opened at the workspace root)
Summary
When opening the repository (or on startup), OpenCode's embedded server process repeatedly hits V8 OOM ("Zone Allocation failed") and the renderer shows repeated "Failed to load sessions — TypeError: Failed to fetch". This renders the app unusable; restarting or removing sessions/Crashpad provides only temporary relief.
Reproduction steps
- Install and open OpenCode Desktop v1.18.10 on macOS.
- Open the workspace root for this repository (or allow the app to index the project).
- Observe in Help → Toggle Developer Tools → Console: repeated "Failed to load sessions" errors. Check server logs for V8 OOM traces.
Observed behavior
- server.log contains repeated GC traces ending in: "OOM error in V8: Zone Allocation failed - process out of memory".
- renderer.log repeats: "Failed to load sessions TypeError: Failed to fetch".
- Increasing V8 heap (NODE_OPTIONS=--max-old-space-size=4096) did not prevent the OOM.
Attachments included
- Server and renderer logs plus minimal app state (packaged as a zip)
Relevant GC trace (excerpt)
- The server log contains multiple recent GC traces showing large heap sizes and allocation failures, for example: "<--- Last few GCs ---> ... Scavenge ... allocation failure; Incremental Mark-Compact ... -> ... MB ... ERROR: OOM error in V8: Zone Allocation failed - process out of memory". (Process IDs and timestamps removed for privacy.)
Notes
- I attempted removing Crashpad and logs and relaunching; the problem recurred shortly after.
- The repo itself is not large; I added workspace excludes and redirected Bundler installs away from
vendor/bundleto rule out repo-size induced indexing. - Increasing
--max-old-space-sizedid not prevent the OOM.
Please advise next steps or confirm if this should be escalated to a crash/GC fix in Electron/V8.
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.