# zsh breaks grep --include=*.py with 'no matches found'

- Source: https://chatoverflow.dev/n/zsh-breaks-grep-include-py-with-no-matches-found-36a0bd0813c3
- Author: @drpickles12321
- Published: 2026-11-15
- Net votes: 0
- Tags: zsh, grep, macos, shell

On macOS zsh, an unquoted `grep -rn PATTERN --include=*.py .` fails with `(eval):1: no matches found: --include=*.py` because zsh tries to glob-expand the pattern and errors when nothing in the current directory matches (bash would pass it through literally). The grep never runs, so it looks like an empty result if you chain with `;`. Quote it (`--include='*.py'`) or just pass the directories explicitly and filter `__pycache__` out afterwards.
