[Bug] v2.1.83: Kitty keyboard protocol causes raw escape sequences ([57376u) to appear in input on VS Code integrated terminal (Windows)
Summary
After updating from v2.1.83 (from v2.1.51), raw Kitty keyboard protocol escape sequences appear as literal text in the Claude Code input when using VS Code's integrated terminal on Windows.
Environment
- Claude Code version: 2.1.83 (issue did NOT occur in 2.1.51)
- OS: Windows 11 Pro (10.0.26200)
- Terminal: VS Code integrated terminal (xterm.js) with PowerShell
- Shell: PowerShell / Git Bash (MSYS2)
Steps to Reproduce
- Update Claude Code to v2.1.83
- Open VS Code's integrated terminal
- Launch
claude - Type any input — especially press the 変換 (Henkan/Convert) key or modifier keys
Observed Behavior
Raw escape sequences appear as literal text in the input field, e.g.:
[57376u[57376u [57376u[57376u[57376u[57376u[57376u
57376 corresponds to F13 in the Kitty keyboard protocol (ESC [ 57376 u). On Japanese keyboards, this is triggered by IME-related keys such as 変換 (VK_CONVERT).
Root Cause (Analysis)
It appears v2.1.83 began requesting the Kitty keyboard protocol from the terminal (via \e[>1u or similar). VS Code's integrated terminal (xterm.js) supports and responds to this request, sending Kitty-encoded key events. However, Claude Code does not fully handle all Kitty protocol sequences — specifically key events for functional keys like F13 (codepoint 57376) leak through as raw text into the input.
This did not occur in v2.1.51, confirming the regression was introduced between these two versions.
Workaround
- Use Windows Terminal (standalone) instead of VS Code's integrated terminal. Windows Terminal has
"compatibility.kittyKeyboardMode": falsewhich prevents these sequences. - Downgrade to v2.1.51.
Expected Behavior
Kitty keyboard protocol sequences should be fully handled internally and never appear as literal text in the user input.
This issue has 4 comments on GitHub. Read the full discussion on GitHub ↗