opencode icon indicating copy to clipboard operation
opencode copied to clipboard

memory leak

Open zx06 opened this issue 4 weeks ago • 5 comments

Description

Image

Plugins

oh-my-opencode

OpenCode version

1.1.3

Steps to reproduce

No response

Screenshot and/or share link

Image

Operating System

windows11

Terminal

windows terminal

zx06 avatar Jan 06 '26 05:01 zx06

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

  • #6449: Big memory leak (10-11GB RAM usage reported)
  • #6213: Memory leak during prolonged usage on Windows 11
  • #6119: Critical memory leak with 72.5G VIRT memory consumption on startup
  • #4315: Memory stays unbounded with detailed analysis of ACP session map and tool output leaks
  • #5363: OpenCode eating 70GB of memory in background session
  • #6571: High memory usage reported

Feel free to ignore if none of these address your specific case.

github-actions[bot] avatar Jan 06 '26 05:01 github-actions[bot]

+1

hffmnnj avatar Jan 06 '26 07:01 hffmnnj

+1

wzx140 avatar Jan 07 '26 11:01 wzx140

Can confirm the memory leak is quite bad on Windows. Typically have to kill OpenCode every 30 minutes (on a 32gb machine).

Just had a long-running prompt (i18n extraction in a codebase) that only did file reads and file writes for a period of time. This alone was clearly leaking as the Bun process raised from initially ~500mb memory to ~1,3gb in a few minutes, and still climbing.

kfuglsang avatar Jan 07 '26 19:01 kfuglsang

I'm using OpenCode on Windows 11 with PowerShell 7. After launching OpenCode, even if I don't initiate any conversation, the memory usage keeps increasing until it completely cripples my system. From Task Manager, I can see that numerous PowerShell processes are being spawned continuously, and new ones keep launching nonstop. I don't understand what's causing this issue.

Image

1075461847 avatar Jan 08 '26 07:01 1075461847