Bash tool returns exit code 127 on every command in 2.1.147
Status Fixed / completed
Reported on v2.1.147
Maintainer reply ✓ Yes — chrislloyd
Workaround ✓ Mentioned in thread ↓
Activity 10 comments · opened May 21, 2026 · closed May 22, 2026
💡 Likely answer: A maintainer (chrislloyd, collaborator)
responded on this thread — see the highlighted reply below.
Summary
In Claude Code 2.1.147, every Bash tool invocation fails with exit code 127, including shell builtins. This makes the Bash tool completely unusable.
Repro
Any Bash tool call fails, e.g.:
echo "hello"→ exit 127pwd && whoami→ exit 127/bin/pwd(absolute path to a real binary) → exit 127
Exit 127 normally means "command not found," but it's firing even for builtins and absolute paths to existing binaries, so it looks like the issue is upstream of the user's shell (the tool wrapper itself, not .bashrc/.zshrc).
Environment
- Claude Code version: 2.1.147
- OS: Linux 6.18.7-76061807-generic (Pop!_OS / Ubuntu-family)
- Shell: bash
Related
- In-app feedback ID:
47de7b0a-a686-4957-aadc-83f44758787d
10 Comments
Found 1 possible duplicate issue:
This issue will be automatically closed as a duplicate in 3 days.
🤖 Generated with Claude Code
Same problem here on
Same problem here, was working fine and after a PC reboot it started showing that 127 code for every bash tool usage now.
Tried restarting WSL/Claude code but no success.
Hitting the same thing on 2.1.147 — every Bash tool call comes back with exit code 127, Pinning to 2.1.145 restores normal behavior, so it looks like a regression introduced in 2.1.147.
I reverted to version 2.1.146 and is working again, so yeah, seems to be a regression introduced on 2.1.147 indeed!
Thanks for the reports (and the feedback id) investigating now.
Confirmed and root-caused issue. Downgrading to
2.1.146is the immediate workaround. Cutting a hotfix now.Still not seeing a new version beyond
2.1.147, but the change logs have been updated?This issue was fixed as of version 2.1.148.
This issue has been automatically locked since it was closed and has not had any activity for 7 days. If you're experiencing a similar issue, please file a new issue and reference this one if it's relevant.