[BUG] LS tool returns empty results for non-empty directories
Environment
- Platform (select one):
- [x] Anthropic API
- [ ] AWS Bedrock
- [ ] Google Vertex AI
- [ ] Other:
- Claude CLI version: 1.0.63 (Claude Code)
- Operating System: macOS (Darwin 15.4.1)
- Terminal: Terminal App - zsh
## Bug Description
The LS tool fails to list files and directories that are present in a directory, returning empty results even when the directory contains multiple items. PS: {user_name} is a placeholder.
## Steps to Reproduce
- Navigate to a directory that contains files (e.g.,
/Users/{user_name}/.claude) - Run
claude "list the directory you're in" - Claude uses the LS tool which returns empty results
- Verify files exist by running
claudethen!ls -lain interactive mode
## Expected Behavior
The LS tool should list all files and directories present in the specified path, similar to the ls command output.
## Actual Behavior
The LS tool returns an empty result showing only the directory path itself:
- /Users/{user_name}/.claude/
Meanwhile, ls -la via Bash tool shows the directory actually contains: ide/, projects/, prompts/, shell-snapshots/, statsig/, todos/
## Additional Context
This bug impacts Claude's ability to explore file systems when invoked with direct commands. The @ mention feature and interactive mode !ls commands work correctly, but the LS tool itself appears broken. Workaround is to use Bash tool with ls commands instead
I have also added LS to the global permissions, I'm still getting the same results:
> list the directory you're in
⏺ I'll list the contents of the current directory.
⏺ List(.)
⎿ Listed 2 paths (ctrl+r to expand)
⏺ The directory /Users/{user_name}/.claude is empty.This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗