[BUG] Claude creating ghost files while using /sandbox
Resolved 💬 3 comments Opened Apr 5, 2026 by theodore-zd Closed Apr 9, 2026
Preflight Checklist
- [ ] 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?
Just trying to bumb this and see if anyone else is also still experiencing this or has found a way to fix it...
During Bash tool execution, Claude Code creates empty (0 byte), read-only (-r--r--r--) dotfiles in the current working directory:
.bashrc
.bash_profile
.gitconfig
.gitmodules
.profile
.ripgreprc
.zprofile
.zshrc
All files are created at the exact same millisecond.
Reproduces consistently across all directories and persists even after full uninstall/reinstall of Claude Code.
SOURCE: https://github.com/anthropics/claude-code/issues/17087
What Should Happen?
Claude should not be creating these ghost files and should have a way to allow accessing specific root files if needed such as .gitconfig etc...
Error Messages/Logs
Steps to Reproduce
run claude in sandboxing mode current config
{
"permissions": {
"allow": [
"WebFetch(domain:proxy.golang.org)",
"Bash(go build:*)"
]
},
"sandbox": {
"enabled": true,
"filesystem": {
"denyRead": [
"~/"
],
"allowRead": [
"."
]
}
}
}
ask to do normal changes in code base and interact with the system and tools like git, for example commiting changes
Claude Model
Opus
Is this a regression?
No, this never worked
Last Working Version
_No response_
Claude Code Version
2.1.92 (Claude Code)
Platform
Anthropic API
Operating System
Other Linux
Terminal/Shell
Other
Additional Information
Running arch specifically CachyOS
using:
- Ghost
- ZSH
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗