[Bug] TUI fails to render with raw ANSI output and critical memory leak (72.5G VIRT) on startup #3840

Open
opened 2026-02-16 17:41:39 -05:00 by yindo · 3 comments
Owner

Originally created by @roymecat on GitHub (Dec 24, 2025).

Originally assigned to: @rekram1-node on GitHub.

Description

I am trying to run opencode on my Debian 13.1. The tool fails to launch the TUI properly. Instead of showing the interface, it floods the terminal with raw ANSI escape sequences (specifically mouse reporting codes like ^[[<35;84;4M).

Crucially, I observed via htop that the process immediately consumed an abnormal amount of memory: 71.9G of VIRT. This suggests a massive memory leak or an infinite allocation loop during the initialization phase.

OpenCode version

latest version

Steps to reproduce

Environment: Debian 13.1(Headless, connected via SSH).
Run the command opencode in a project directory.
The terminal output becomes corrupted with raw escape codes.
Check process status in htop.

Screenshot and/or share link

Image Image

Operating System

Debian 13.1

Terminal

No response

Originally created by @roymecat on GitHub (Dec 24, 2025). Originally assigned to: @rekram1-node on GitHub. ### Description I am trying to run opencode on my Debian 13.1. The tool fails to launch the TUI properly. Instead of showing the interface, it floods the terminal with raw ANSI escape sequences (specifically mouse reporting codes like ^[[<35;84;4M). Crucially, I observed via htop that the process immediately consumed an abnormal amount of memory: 71.9G of VIRT. This suggests a massive memory leak or an infinite allocation loop during the initialization phase. ### OpenCode version latest version ### Steps to reproduce Environment: Debian 13.1(Headless, connected via SSH). Run the command opencode in a project directory. The terminal output becomes corrupted with raw escape codes. Check process status in htop. ### Screenshot and/or share link <img width="3183" height="503" alt="Image" src="https://github.com/user-attachments/assets/ac9e4ee7-64c1-4a52-aefd-efe1547a48bc" /> <img width="3172" height="641" alt="Image" src="https://github.com/user-attachments/assets/0a8947cd-e094-4490-800c-5601b449fa61" /> ### Operating System Debian 13.1 ### Terminal _No response_
yindo added the opentuibugperf labels 2026-02-16 17:41:39 -05:00
Author
Owner

@github-actions[bot] commented on GitHub (Dec 24, 2025):

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

  • #5990: Bug: Ctrl+C interruption in opencode causes terminal corruption with ANSI escape sequences
  • #6080: OpenCode TUI Hangs on Fedora Linux (npm & bun & standalone)
  • #6057: Nothing is displayed

These issues report similar symptoms of TUI rendering failures, ANSI escape sequence corruption, and memory/hanging issues on Linux systems. Feel free to ignore if your specific case differs from these.

@github-actions[bot] commented on GitHub (Dec 24, 2025): This issue might be a duplicate of existing issues. Please check: - #5990: Bug: Ctrl+C interruption in opencode causes terminal corruption with ANSI escape sequences - #6080: OpenCode TUI Hangs on Fedora Linux (npm & bun & standalone) - #6057: Nothing is displayed These issues report similar symptoms of TUI rendering failures, ANSI escape sequence corruption, and memory/hanging issues on Linux systems. Feel free to ignore if your specific case differs from these.
Author
Owner

@mohamedbouddi7777-dev commented on GitHub (Feb 1, 2026):

Free the world

@mohamedbouddi7777-dev commented on GitHub (Feb 1, 2026): Free the world
Author
Owner

@MorganMarshall commented on GitHub (Feb 1, 2026):

Bump

@MorganMarshall commented on GitHub (Feb 1, 2026): Bump
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#3840