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
Numpad keys not working when running inside VS Code 1.110 integrated terminal #16100
Numpad keys (0-9, Enter, decimal, operators) are completely ignored by OpenCode's TUI when running inside VS Code 1.110.0's integrated terminal. The numpad works correctly in the terminal shell before launching OpenCode, and works correctly when running OpenCode in an external terminal.
Environment
OpenCode version: 1.2.17 (also tested with 1.2.15, same issue)
VS Code Version: 1.110.0 (Electron 39.6.0, Chromium 142.0.7444.265)
OS: Windows (connecting via Remote SSH to Ubuntu ARM64)
Terminal: VS Code integrated terminal
Steps to Reproduce
Open VS Code 1.110.0 integrated terminal
Verify numpad works in the shell (it does)
Launch opencode
Try typing numbers using the numpad
Observe: numpad keystrokes are completely ignored
Expected Behavior
Numpad keys should produce the same input as the main keyboard number row.
Actual Behavior
Numpad keys are silently dropped inside OpenCode's TUI
Main keyboard number row works correctly
Numpad works in the terminal before launching OpenCode
Numpad works when running OpenCode in an external terminal (outside VS Code)
Issue occurs on both OpenCode 1.2.15 and 1.2.17
Analysis
VS Code 1.110.0 updated to Electron 39 / Chromium 142, which has a known regression where numpad keys report key: "Unidentified" in key events (Chromium issues 405793116, 429730008).
The normal terminal shell compensates via keyCode fallback, but when OpenCode's opentui activates enhanced keyboard mode (Kitty keyboard protocol / CSI u), xterm.js passes the broken key identity through. OpenCode's TUI receives unidentifiable key events for numpad keys and drops them.
Reacted by Rüdiger Busche, Oleksandr, Daniel Grenner, Sébastien Baillou, Estudio PWS, David Vadas, vysmaty, Matt Johnson-Pint, Marco Lefrancois, Lukas van der Stok and 8 more
I can confirm this issue still exists on OpenCode 1.3.6.
Environment:
Host OS: Windows 11 desktop
VS Code Remote - WSL: Ubuntu 24.04.4 LTS
VS Code Remote - SSH: Ubuntu 22.04 server
OpenCode: 1.3.6
I can reproduce the same problem in both setups:
a local WSL Ubuntu session in VS Code
an SSH remote session in VS Code
In both cases, the numeric keypad on the right side of the keyboard is still unusable inside OpenCode. Upgrading to 1.3.6 did not resolve it.
So this does not seem limited to a single Ubuntu installation or only to WSL. It also reproduces when connected to a remote Ubuntu 22.04 server over SSH from VS Code.
If needed, I can also provide the exact VS Code version and test additional workarounds.
Same issue on MacOS, OpenCode 1.3.17 with iTerm 2 3.6.9 (standalone and integrated terminal). However, using built-in Terminal.app the NumPad works in OpenCode.
@Noitidart this would not work when using it remote/via ssh, so I would make the useKittyKeyboard option reactive optionally to use renderer.capabilities. But as the way you did it alleviates some pain I'll merge it like that shortly.
I just saw this: microsoft/vscode#286897 - it enables kitty keyboard support in the vscode integrated terminal. Turning it off for all vscode versions generally would prevent proper behaviour for versions that support kitty keyboard.
@kommander so i just checked and this is true for me screenshot. so this means vscode supports kitty and then we shouldnt do this PR? instead the fix is elsewhere?
Activity
Magneticdud commentedon Mar 5, 2026
This problem of the numpad not working also happens with Alactritty on (Fedora) Linux. With GNOME terminal or with kitty, the numpad works
GeneratedRandomly commentedon Mar 9, 2026
same under opencode 1.2.23, vscode 1.111.0, WSL2-ubuntu 22.04
mkdgs commentedon Mar 10, 2026
Same here on debian trixie, opencode 1.2.24 and vscode 1.111.0 . That appear after apt update, so seems to be a vscode related change.
ACCSCI commentedon Mar 12, 2026
Same here on Ubuntu 24.04.4 LTS, vscode 1.111.0,opencode extension 0.0.13,opencode 1.2.24
aborruso commentedon Mar 14, 2026
same under opencode 1.2.26, vscode 1.111.0, WSL2 (Pengwin 12/bookworm). numpad is disabled for me too.
mcpbay commentedon Mar 20, 2026
Same under OpenCode 1.2.27, VSCode 1.112.0, WSL.
dgsosa commentedon Mar 23, 2026
Same under OpenCode 1.3.0, VSCode 1.112.0 on Windows 11.
under integrated terminal, and under extension (v 0.0.13 )
CODLOP commentedon Mar 25, 2026
Same under OpenCode 1.3.2, VSCode 1.112.0 on Windows 11.
under integrated terminal, and under extension (v 0.0.13 )
RiAnBee commentedon Mar 30, 2026
I can confirm this issue still exists on OpenCode 1.3.6.
Environment:
I can reproduce the same problem in both setups:
In both cases, the numeric keypad on the right side of the keyboard is still unusable inside OpenCode. Upgrading to 1.3.6 did not resolve it.
So this does not seem limited to a single Ubuntu installation or only to WSL. It also reproduces when connected to a remote Ubuntu 22.04 server over SSH from VS Code.
If needed, I can also provide the exact VS Code version and test additional workarounds.
lekoala commentedon Apr 1, 2026
same issue, running in vscode integrated terminal
xinychan commentedon Apr 3, 2026
Same under OpenCode 1.3.13, OpenCode extension 0.0.13,VSCode 1.114.0 on Windows 10.
paul-vd commentedon Apr 5, 2026
Same issue here using OpenCode 1.3.15.
Numpad works fine in normal terminal as well as ghostly
jmskov commentedon Apr 6, 2026
Same issue on MacOS, OpenCode 1.3.17 with iTerm 2 3.6.9 (standalone and integrated terminal). However, using built-in Terminal.app the NumPad works in OpenCode.
14 remaining items
Noitidart commentedon May 22, 2026
@kommander can I please get a review - I rebased and tested it again to catch it up to current - #27665 (comment)
kommander commentedon May 22, 2026
@Noitidart this would not work when using it remote/via ssh, so I would make the
useKittyKeyboardoption reactive optionally to userenderer.capabilities. But as the way you did it alleviates some pain I'll merge it like that shortly.kommander commentedon May 22, 2026
I just saw this: microsoft/vscode#286897 - it enables kitty keyboard support in the vscode integrated terminal. Turning it off for all vscode versions generally would prevent proper behaviour for versions that support kitty keyboard.
Noitidart commentedon May 23, 2026
Oh got it, thank you @kommander for the review! So if kitty is coming to vscode then this isn't needed for sure.
Noitidart commentedon May 23, 2026
@kommander I noticed microsoft/vscode#286897 is from Jan 10 2026 - but its now May 23 2026 - maybe they didn't land kitty as we are thinking?
kommander commentedon May 26, 2026
Maybe it still needs to be activated explicitly with
terminal.integrated.enableKittyKeyboardProtocol=trueNoitidart commentedon May 27, 2026
@kommander so i just checked and this is true for me screenshot. so this means vscode supports kitty and then we shouldnt do this PR? instead the fix is elsewhere?
tristan957 commentedon Jul 15, 2026
For what its worth. numpad Enter doesn't work for me on Ghostty.
github-actions commentedon Sep 14, 2026
To stay organized issues are automatically closed after 60 days of no activity. If the issue is still relevant please open a new one.