[BUG] Immediate Undo Execution on Partial Input Erases Progress (and Lacks Access to Forked Conversation Branches)
Environment
- Platform: Claude Code in-terminal AI coding assistant
- Claude CLI version: 0.2.37
- Operating System: macOS 15.3.1
- Terminal: Cursor/Zsh
Bug Description
When attempting to undo a step by typing "20", the system immediately executed an undo command upon typing the first character ("2"), reverting to "step 2" and erasing a significant amount of progress (steps 3 through 20). The system indicated that the conversation would "fork" at this point, but there is no apparent way to access the alternative branches of the conversation to recover the lost progress.
<img width="304" alt="Image" src="https://github.com/user-attachments/assets/3c55963e-8ca7-412c-9726-022bd30ac73a" />
Steps to Reproduce
- Open Claude Code in the terminal and interact with Claude Code for 20+ steps.
- Attempt to undo to "step 20" by accessing the undo menu and typing "20".
- Observe that the system jumps to "step 2" as soon as "2" is typed, erasing progress.
Expected Behavior
The system should allow the user to complete typing "20" before executing the undo command. Additionally, if a conversation is forked, there should be a clear method to access and navigate between the different branches.
Actual Behavior
The system immediately executed an undo command upon typing "2", reverting to "step 2" and erasing all subsequent progress. There is no apparent way to access the alternative branches of the conversation.
Additional Context
No error messages were displayed. Attempts to recover the lost progress were unsuccessful due to the lack of access to the conversation branches.
This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗