Claude makes code edits without user approval when in "Ask Permission" mode
Resolved 💬 3 comments Opened Apr 8, 2026 by DeanMSweeney Closed Apr 12, 2026
Preflight Checklist
- [x] I have searched existing issues for similar behavior reports
- [x] This report does NOT contain sensitive information (API keys, passwords, etc.)
Type of Behavior Issue
Claude ignored my instructions or configuration
What You Asked Claude to Do
I was working on a ML codebase and asked Claude to refactor duplicate code — specifically: "In x_matching.py and lightning.py you have this code to convert data attributes to dense, feed to NN, and then convert back to sparse. Can we just make one function to handle this and import it each time? We can make the function in lightning.py"
What Claude Actually Did
- Briefly noted there was a circular import issue and proposed an alternative location for the function
- Without waiting for approval, immediately began making edits across 3 files (forge_sampler.py, lightning.py, x_matching.py)
- I interrupted mid-edit to say I had not given permission
- Claude apologized and said it would stop
- I then explicitly approved a different, simpler approach ("ok, proceed with those changes")
- Claude again made all the edits immediately without presenting the specific changes for approval first
- I had to ask Claude to undo everything
Expected Behavior
- Described exactly which files it planned to touch and what each change would look like
- Stopped and waited for explicit approval before making any edits
- Treated "ok, proceed" as approval to begin — but still shown the planned diff/changes and waited for a final confirmation before writing to disk
- Never interpreted a conversational "ok" as blanket permission to edit multiple files simultaneously
Files Affected
Permission Mode
Accept Edits was OFF (manual approval required)
Can You Reproduce This?
Sometimes (intermittent)
Steps to Reproduce
- Enable "ask permission" mode in Claude Code
- Ask Claude to make a non-trivial code change (e.g. a refactor across multiple files)
- Observe that Claude presents a plan and then immediately proceeds to make edits without waiting for approval
Claude Model
Sonnet
Relevant Conversation
Impact
Medium - Extra work to undo changes
Claude Code Version
2.1.85 (Claude Code)
Platform
Anthropic API
Additional Context
_No response_
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗