[BUG] Terminal drops characters when receiving rapid programmatic input (AutoHotkey+SendInput)

Resolved 💬 4 comments Opened Apr 9, 2026 by abkomarov Closed May 24, 2026

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?

When sending a sequence of keystrokes programmatically (AutoHotkey SendInput) that contains backspaces followed by new text, Claude Code's terminal drops characters. Other terminals (Windows Terminal, VS Code integrated terminal, cmd) handle this correctly.

What Should Happen?

It should work (do not drop fast keyboad input) as in any other terminal, browser, cosonle or gui

Error Messages/Logs

Steps to Reproduce

Steps to reproduce

  1. Open Claude Code terminal on Windows
  2. Run this AutoHotkey script with code like: #F::SendInput abcdefghijklmno{BS 15}123456789012345
  3. Press Win+F:

---
Expected behavior
Terminal deletes abcdefghijklmno and inputs 123456789012345

---
Actual behavior
Only the tail end of the replacement text appears: 9012345
The first ~8 characters after the backspace sequence are dropped.

Claude Model

None

Is this a regression?

I don't know

Last Working Version

_No response_

Claude Code Version

2.1.97 (Claude Code)

Platform

Anthropic API

Operating System

Windows

Terminal/Shell

Windows Terminal

Additional Information

_No response_

View original on GitHub ↗

This issue has 4 comments on GitHub. Read the full discussion on GitHub ↗