[BUG] CC keeps asking for permission when square brackets are in the file name
Resolved 💬 6 comments Opened Nov 9, 2025 by SimonDeconde Closed Jan 12, 2026
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?
Bug: Permission system doesn't persist for files with square brackets
### Description
Permission prompts repeat for the same file even after selecting "Yes, allow all edits during this session"
### File path
apps/settings/[id]/[[...tab]].tsx
### Expected behavior
After selecting "allow all edits during this session", subsequent edits to the same file should not prompt for permission
### Actual behavior
Permission prompt reappears for every edit to this file
### Hypothesis
Square brackets in Next.js dynamic route filenames may interfere with path matching in the permission system
What Should Happen?
Claude Code should ask only once.
Error Messages/Logs
Steps to Reproduce
- Read/write file with square brackets in the name.
- Allow command for the session
- Read/write again
- Observe that Claude Code continues to ask
Claude Model
None
Is this a regression?
Yes, this worked in a previous version
Last Working Version
_No response_
Claude Code Version
2.0.36
Platform
Anthropic API
Operating System
macOS
Terminal/Shell
Warp
Additional Information
_No response_
This issue has 6 comments on GitHub. Read the full discussion on GitHub ↗