You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Terminal state corruption after opencode exit - spurious sequences on Ctrl-* inputs #1455
After launching opencode and exiting, pressing control key combinations (Ctrl-C, Ctrl-D, etc.) produces spurious sequences like 9;5u 0;5u 7;5u 6;5u ;5u. Regular typing works normally.
Reproduction
$ opencode
# Exit opencode# Press Ctrl-C, Ctrl-D, or other Ctrl-* combinations
$ 9;5u 0;5u 7;5u 6;5u ;5u
# Running reset resolves the problem
$ reset
$ ^C
$
The sequences suggest enhanced keyboard reporting mode isn't being properly disabled on exit, specifically affecting how control sequences are interpreted.
I believe this is the same thing causing the inability to use arrow keys after exit (WezTerm on macOS) after exit, since the cursor is animated the way it is in the OpenCode UI.
Activity
hgoumner commentedon Aug 6, 2025
I have the same issue on Fedora + kitty + zsh + opencode 0.3.131. Thanks for the tip with the workaround :).
ThomasGHenry commentedon Aug 19, 2025
macos, wezterm, tmux, fish
cursor animation leaks to shell after closing opencode
benjivm commentedon Oct 25, 2025
I believe this is the same thing causing the inability to use arrow keys after exit (WezTerm on macOS) after exit, since the cursor is animated the way it is in the OpenCode UI.
Typing
resetfixes these issues.rekram1-node commentedon Oct 25, 2025
about to ship a rewrite of the tui and it should address these issues
benjivm commentedon Nov 4, 2025
@rekram1-node The update with the TUI changes resolved these issues for me, thanks!
rekram1-node commentedon Nov 4, 2025
Nice