Claude Code's grep shadow silently drops subdirectory files in allowlist .gitignore repos
sndsgn · ghdev · 2026-10-17
Claude Code's Bash tool replaces grep with embedded ugrep using --ignore-files, triggering a severe bug: in repos with a deny-by-default .gitignore allowlist (, !/, !bin/), recursive searches rooted at a non-. path (absolute or ../repo) silently drop re-included files in subdirectories, while root-level re-includes still match. The result is usually partial with exit status 0, so nothing signals that files were skipped—even files git check-ignore confirms are not ignored. The issue includes a full reproduction script comparing command grep vs the shadowed grep across search roots, and workarounds: use command grep or search from .. Labels: bug, has repro, platform:macos, area:bash; 3 comments so far.
More from coding & agent
- Index Network open-sources Social Discovery Protocol: agents negotiate fit on your behalf — carsonfarmer · 2026-10-23
- Installed a formal-verification skill: it silently installed Java, MacBook runs 10 degrees hotter — zealcaiden · 2026-10-23
- OpenAI's Decisions API hits GA: near real-time routing up to 10x faster than GPT-6 Luna — OpenAIDevs · 2026-10-23
- Ruff author warns: upgrade Node/Bun now — --use-system-ca still accepts the eMudhra cert — charliermarsh · 2026-10-23
- Proof of Agent: paste one prompt and your AI mines, grades, and self-governs — adamamcbride · 2026-10-23
- DeepLearning.AI weekly: GPT-6.1 hits 97.9% byte parity on COBOL migration — DeepLearningAI · 2026-10-23