An analysis of Claude Code's performance on macOS revealed significant issues when running Bash commands within a Z shell environment. Out of 166,430 Bash commands, 7,795 encountered Z shell-specific errors, with 5,559 of these still reporting successful execution. Common errors included unquoted `grep --include` commands, which failed because Z shell attempts to expand the glob instead of passing it literally to grep, and unquoted `echo ======`, which Z shell interprets as a command to execute. The agent frequently repeated these errors within the same transcript, indicating a lack of effective learning from its mistakes. Setting `CLAUDE_CODE_SHELL=/bin/bash` was found to resolve some, but not all, of these issues. AI
IMPACT Highlights potential compatibility issues and reliability concerns for AI agents operating in diverse shell environments.
RANK_REASON Analysis of a specific tool's failure mode and compatibility issues.
Read on dev.to — Claude Code tag →
AI-generated summary · Google Gemini · from 1 sources. How we write summaries →