[BUG] Claude Code unable to use bash commands after 15-20 minutes of usage
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?
System Information:
Claude Version = 1.0.58 (Claude Code)
NAME="Ubuntu"
VERSION="20.04.6 LTS (Focal Fossa)"
ID=ubuntu
ID_LIKE=debian
PRETTY_NAME="Ubuntu 20.04.6 LTS"
VERSION_ID="20.04"
When I start up Claude Code I periodically run into issues with shell snapshots.
This happens after 15-20 minutes of usage, and doesn't go away until I restart. It happens much more frequently when I am running two Claude Code instances on the same machine (each running in a completely separate repo &directory).
What Should Happen?
Claude should be able to find the snapshot and run bash commands.
Error Messages/Logs
Task(Update Lambda IAM policy)
⎿ Bash(my-command-goes-here)
Waiting…
Error: /bin/bash:
/home/username-goes-here/.claude/shell-snapshots/snapshot-bash-1760151834754-yf0jld.sh:
No such file or directory
Steps to Reproduce
1) Start up a Claude instance (instance-1)npm install -g @anthropic-ai/claude-code
claude
2) Ask instance-1 to do something - let it runrepeat ten times: create a text file with 42 zeroes named "foo_bar.txt", sleep for a minute, overwrite the text file with the exact same contents
3) Open a new terminal, change to a separate directory, start up Claude instance (instance-2)cd ../new-dir-name/
claude
4) Tell instance-2 to do something elserepeat ten times: create a text file with a randomly generated dad joke named "dad_jokes.txt", sleep for a minute, overwrite the text file with another randomly generated dad joke
5) Wait for the errors to start showing up in either instance. Usually it will be the second instance (instance-2 here).
Claude Model
Not sure / Multiple models
Is this a regression?
Yes, this worked in a previous version
Last Working Version
_No response_
Claude Code Version
1.0.58
Platform
Anthropic API
Operating System
Ubuntu/Debian Linux
Terminal/Shell
Other
Additional Information
_No response_
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗