Korean IME toggle key (한영키) prints raw escape sequence `[57358u`
Status Fixed / completed
Reported on v2.1.84
Maintainer reply ✓ Yes — ashwin-ant
Workaround ✓ Mentioned in thread ↓
Activity 5 comments · opened Mar 26, 2026 · closed Apr 18, 2026
💡 Likely answer: A maintainer (ashwin-ant, collaborator)
responded on this thread — see the highlighted reply below.
Preflight Checklist
- [x] I have searched existing issues and this hasn't been reported yet
- [x] This is a single bug report (please file separate reports for different bugs)
- [x] I am using the latest version of Claude Code
What's Wrong?
Pressing the Korean/English IME toggle key (한영키) inside Claude Code prints the raw Kitty keyboard protocol escape sequence [57358u as text input instead of toggling the input method.
This only happens inside Claude Code — the same key works correctly in all other terminal applications and the host terminal emulator itself (Terminal.app, iTerm2, etc.).
What Should Happen?
The 한영키 press should either:
- Be silently ignored and let the OS handle IME switching
- Trigger the OS-level input source switch normally
No raw escape sequence should be printed as text.
Error Messages/Logs
[57358u
Steps to Reproduce
- Set up macOS with Korean input source (2-Set Korean / 두벌식)
- Open Claude Code CLI in terminal
- Press the 한영키 (Korean/English toggle key) on your keyboard
- Observe
[57358uprinted in the input area
Note: This does not happen in any other terminal application — only inside Claude Code's TUI.
Claude Model
Opus
Is this a regression?
Yes, this worked in a previous version
Last Working Version
_No response_
Claude Code Version
2.1.84
Platform
Anthropic API
Operating System
macOS
Terminal/Shell
VS Code integrated terminal
Additional Information
- Running Claude Code as VS Code extension (not standalone CLI)
- The 한영키 keycode
57358is from the Kitty keyboard protocol (CSI 57358 u) - Claude Code's TUI framework intercepts the key but doesn't handle it, causing the raw sequence to be printed as text
- Workaround: Use Caps Lock or Control+Space for input source switching instead of 한영키
- This affects all Korean macOS users who use the dedicated 한영 key for IME toggling
5 Comments
This issue only occurs when Native UI is enabled. It does not reproduce in the standard terminal UI
mode.
Fix found for the \
[57358u\/ Caps Lock escape sequence issue!If you're experiencing this with Caps Lock (or any input source switch key), there's a VS Code keybinding workaround that takes about 1 minute:
Cmd\+ \Shift\+ \P\[ ]\array:\
\\json\{
"key": "capslock",
"command": "workbench.action.terminal.focus",
"when": "terminalFocus"
}
\
\Cmd\+ \S\) — no restart needed.This intercepts the Caps Lock key in the terminal so xterm.js doesn't forward the raw kitty protocol escape sequence into input. OS-level input source switching still works normally.
Full explanation in: anthropics/claude-code#39231
/tmp/kitty-comment.md
This was fixed in v2.1.85 — The Korean IME toggle key (한영키) no longer inserts the raw escape sequence
[57358uinto the input. If you're still seeing this in the latest version, please comment with your version and repro and we'll reopen.This issue has been automatically locked since it was closed and has not had any activity for 7 days. If you're experiencing a similar issue, please file a new issue and reference this one if it's relevant.