[BUG] Commands that should be allowed according to settings are not being allowed
Resolved 💬 3 comments Opened Sep 12, 2025 by nbrustein Closed Sep 12, 2025
Preflight Checklist
- [x] I have searched existing issues and this hasn't been reported yet
- [x] This is a single bug report (please file separate reports for different bugs)
- [x] I am using the latest version of Claude Code
What's Wrong?
In .claude/settings.json, I have the following:
{
"permissions": {
"allow": [
"Bash(yarn*)",
But claude is still asking me for permission to run yarn commands. Note in the following chat that claude code itself believes that this is a bug:
⏺ Now let's test the TypeScript compilation to make sure everything is working:
⏺ Bash(yarn tsc)
⎿ No (tell Claude what to do differently)
> why are you asking me for permission to run `yarn tsc`. I see this `allow` entry in settings: `"Bash(yarn*)",`. Shouldn't that give you permission to run all
yarn commands?
⎿ ⧉ Selected 1 lines from .claude/settings.json in Cursor
⏺ You're absolutely right! The settings clearly show "Bash(yarn*)" which should allow all yarn commands including yarn tsc. This seems like a bug in the
permission system - the wildcard pattern should match yarn tsc but it's still asking for permission.
Let me try running the command:
⏺ Bash(yarn tsc)
⎿ Running…
╭─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮
│ Bash command │
│ │
│ yarn tsc │
│ Check TypeScript compilation after removing legacy support │
│ │
│ Do you want to proceed? │
│ ❯ 1. Yes │
│ 2. Yes, and don't ask again for yarn tsc commands in /Users/nbrustein/code/back_royal │
│ 3. No, and tell Claude what to do differently (esc) │
╰─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
What Should Happen?
Claude should be empowered to run all yarn commands when I allow "Bash(yarn*)" in settings
Error Messages/Logs
Steps to Reproduce
- Add an allow setting for
"Bash(yarn*)" - Do something in claude code that will require it to run a yarn command
- See that it asks for permission
Claude Model
Sonnet (default)
Is this a regression?
No, this never worked
Last Working Version
_No response_
Claude Code Version
1.0.112
Platform
Anthropic API
Operating System
macOS
Terminal/Shell
Cursor
Additional Information
_No response_
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗