Bash shell snapshot errors on Windows with Cygwin - snapshot files not found
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 running Bash commands through Claude Code on Windows (using Cygwin), I'm getting repeated errors about missing snapshot files:
/usr/bin/bash: line 1: /cygdrive/c/Users/12477/.claude/shell-snapshots/snapshot-bash-1771380687792-iicuq6.sh: No such file or directory
/usr/bin/bash: line 1: /cygdrive/c/Users/12477/AppData/Local/Temp/claude-b011-cwd: No such file or directory
These errors appear frequently, especially when running simple commands like git fetch.
The snapshot file path changes between runs (different timestamps/IDs). Commands still execute successfully, but the error messages are distracting and
suggest there may be an underlying issue with shell session management.
What Should Happen?
Commands should execute cleanly without snapshot errors in stderr.
The snapshot functionality should either:
- Work correctly without file-not-found errors
- Have robust error handling that suppresses these errors when snapshots aren't critical
- Provide an option for users to disable snapshot functionality if it's not essential for their use case
Error Messages/Logs
/usr/bin/bash: line 1: /cygdrive/c/Users/12477/.claude/shell-snapshots/snapshot-bash-1771380687792-iicuq6.sh: No such file or directory
/usr/bin/bash: line 1: /cygdrive/c/Users/12477/AppData/Local/Temp/claude-b011-cwd: No such file or directory
Steps to Reproduce
- Use Claude Code on Windows 11 with Cygwin bash
- Run any Bash command through Claude Code (e.g.,
git fetch) - Observe stderr output for snapshot-related errors
Claude Model
Other
Is this a regression?
I don't know
Last Working Version
_No response_
Claude Code Version
2.1.39
Platform
Other
Operating System
Windows
Terminal/Shell
Other
Additional Information
_No response_
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗