opencode icon indicating copy to clipboard operation
opencode copied to clipboard

opentui: Rapid blinking in iTerm2

Open Mishkun opened this issue 2 months ago • 3 comments

Description

after updating to 1.x I see annoying rapid blinking of cursor in iTerm2. Not reproducable in stock Terminal app

OpenCode version

v1.0.11

Steps to reproduce

  1. launch opencode
  2. blink blink blink

Screenshot and/or share link

https://github.com/user-attachments/assets/e880ef33-3690-4f05-8d0c-2317e0f8c978

Operating System

macos

Terminal

iTerm2

Mishkun avatar Nov 02 '25 23:11 Mishkun

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

  • #1905: Both report unwanted cursor blinking behavior that started after OpenCode updates - #1905 mentions cursor blinking in Gnome Terminal since v0.4.27, while this issue reports rapid blinking in iTerm2 after updating to v1.x

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

github-actions[bot] avatar Nov 02 '25 23:11 github-actions[bot]

Had the same issue

ravshansbox avatar Nov 02 '25 23:11 ravshansbox

Same issue... 1.0.15 iTerm2 3.6.5, macOS Sequoia, M4 MBP.

Update: Was able to replicate this with two different install methods:

  • brew install opencode
  • npm install -g opencode-ai

Additionally, i used the official install script and for an unknown reason, this one does not contain the flickering cursor VERSION=1.0.15 curl -fsSL https://opencode.ai/install | bash

Side note, I really wish there was a way to NOT have this script modify user zshrc without permission (or at least a way to disable it), as this gets messy in a user's dotfiles. Definitely should at least be a variable reference to disable modifying a user config without their consent.

Lastly, there's no obvious way to "uninstall" when using the official script. Looks like it should only really require removing the new $PATH reference in the user's profile as well as the ~/.opencode folder. I'll see if I can get a PR in to add some of these options, soon as i get a free moment.

Since i was able to reproduce the issue with 2/3 installs, I'm hoping this helps with determining the root cause of the cursor flickering/blinking.

scottrbaxter avatar Nov 03 '25 04:11 scottrbaxter

Fast fix is this setting

Image

in iterm 2 is fixing the issue

Image

Anyway I found how to fix in opentui, will do PR there

istarkov avatar Nov 09 '25 11:11 istarkov