GeezerVison is showing github.com — Opencode freezes when pressing `option` + left arrow key on MacBook with high CPU usage · Issue #2688 · anomalyco/opencode
Opencode freezes when pressing option + left arrow key on MacBook with high CPU usage #2688DescriptionWhen I'm in opencode, and I press option + left arrow key, opencode freezes and I notice this process that spikes:
 Activityrekram1-node commented on Sep 19, 2025 aemr3 commented on Sep 19, 2025
When I'm in opencode, and I press option + left arrow key, opencode freezes and I notice this process that spikes:
yes I have experienced it as well, I'm using shift + arrow keys without any problems.
{
"keybinds": {
"session_child_cycle": "shift+right",
"session_child_cycle_reverse": "shift+left"
}
}
lloydrichards commented on Sep 29, 2025 Just ran into the same issue since v0.13.4 (see #2854) but also noticed that it only had this issue with Ghostty (1.2.0). Will close my other issue and follow this one for a solution 🤞 lloydrichards commented on Oct 1, 2025 in v0.13.7, I'm no longer having this issue Reacted by Towry Wang Reacted by Hani towry commented on Oct 24, 2025 pedropombeiro commented on Feb 7, 2026 I've traced the root cause of this issue to the @opentui/core package's stdin buffer handling.
Root Cause
In packages/core/src/lib/stdin-buffer.ts, the isCompleteSequence function doesn't handle double-escape sequences (like \x1b\x1b[D for Option+Left). When the terminal sends this sequence:
- The function sees it starts with ESC (
\x1b)
afterEsc = \x1b[D (starts with ESC, not [)
- None of the pattern checks match
- Falls through to
return "complete" - treating \x1b\x1b as complete
- The remaining
[D is emitted as literal text
This is why users see [D or [C printed instead of cursor movement.
Filed Upstream
I've filed an issue with a proposed fix in the opentui repo:
anomalyco/opentui#644 github-actions commented on Apr 9, 2026 To stay organized issues are automatically closed after 90 days of no activity. If the issue is still relevant please open a new one.
MetadataMetadataDevelopmentNo branches or pull requestsIssue actions
|