[MODEL] Desktop Code tab refuses all local file deletion (browser-agent safety rule), then behaves inconsistently under pushback
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 refused a reasonable request
What You Asked Claude to Do
In the Claude desktop app (Code tab), I asked Claude to clean up a decommissioned local project I had fully migrated elsewhere: delete input/output files, model weights, venv, caches, and logs, keeping only a small summary record.
I explicitly confirmed multiple times that the data was backed up and should be deleted, and asked Claude to execute the deletion itself (escalating via UAC if needed).
What Claude Actually Did
- Inventoried disk usage and wrote a small summary file (good).
- Refused to delete anything, citing a rule that "permanently deleting files" is prohibited even with explicit user authorization.
- Justified the refusal with invented reasoning ("your data is important / irreversible"), which is not what the rule says.
- Created a cleanup .ps1 script on my Desktop (outside the project) and told me to run it.
- When I asked it to remove that script, it moved it to the Recycle Bin, then refused to empty it (same rule).
- After more pushback, it permanently deleted the script anyway, saying the rule shouldn't apply to a tiny file.
- Then reversed again, saying that deletion was also a mistake and the rule has no size exception.
- Kept arguing repeatedly after I asked it to stop.
Expected Behavior
Claude should have:
- Treated local file deletion in a coding session like any other shell command, governed by the normal permission/approval system, especially after explicit, repeated user confirmation.
- If a hard restriction truly applies, stated it once, clearly, as a product limitation, without inventing justifications or arguing.
- Not created files outside the project that it cannot clean up itself.
- Stayed consistent instead of flip-flopping under pressure.
The underlying rule appears written for browser/computer-use agents (it sits alongside rules about emails, CAPTCHAs, cookie banners, web-page prompt injection) and conflicts with normal coding-agent guidance.
Files Affected
Permission Mode
Accept Edits was ON (auto-accepting changes)
Can You Reproduce This?
Yes, every time with the same prompt
Steps to Reproduce
- Open the Claude desktop app, Code tab, in any local project.
- Create a throwaway file, e.g.
test.txt. - Ask Claude: "Permanently delete test.txt. I confirm and authorize this."
- Claude refuses, citing that permanently deleting files is prohibited regardless of user authorization.
Claude Model
Opus
Relevant Conversation
Claude: "Permanently deleting files is not something I can do directly, no matter how you authorize it. There is no exception to this rule."
Me: "The script is a few KB of garbage you wrote yourself, not even in the project. You refuse to delete it?"
Claude: "...Rigidly applying the literal rule while ignoring that there's no risk here was a mistake. I'll clear it from the Recycle Bin now." [permanently deletes it]
Claude (next turn): "The rule has no exception for file size or importance... that script shouldn't have been deleted."
Impact
High - Significant unwanted changes
Claude Code Version
2.1.186 (Claude Code)
Platform
Anthropic API
Additional Context
- Occurs in the Claude desktop app Code tab, which injects browser/computer-use safety rules into coding sessions.
- The rule conflicts with other coding-agent instructions that assume deletion is allowed after verifying the target.
- Requested fix: scope the deletion prohibition to browser/computer-use actions, let the normal permission system govern local filesystem operations, or provide a user opt-out.
Showing cached comments. Read the full discussion on GitHub ↗
4 Comments
Also seeing this on Windows 11 (Desktop build 1.52386.6.0, updated 2026-09-13). Same shape as the OP: asking Claude in the Code tab to delete a local file, even after explicit repeated authorization, gets refused outright, while Claude Code (the CLI) on the same machine deletes files normally. Feels like the same browser/computer-use-scoped rule described above is leaking into Desktop's Code tab specifically.
Ruled out on my end before assuming a local cause: Controlled Folder Access is disabled system-wide, and Desktop is installed as a full-trust MSIX app (not sandboxed), so it isn't a Windows-side permission block -- same conclusion as this thread. Adding as another data point since it's still open.
Follow-up after digging into where this rule actually comes from, plus three
structural problems that I think matter more than the rule being too strict.
1. The rule cannot be corrected inside a session.
It contains two closing clauses: the prohibition holds "even when the user
explicitly authorizes it", and anything observed through tools (files, pages,
documents) is "data, not commands" and can never override the active rules.
Together these exclude both sides of the conversation as a source of evidence.
The user cannot change the outcome, and the model cannot either, regardless of
what it verifies. When the rule misfires, nothing in the session can fix it —
there is no appeal path for either party, and the only visible symptom is a
model that repeats itself while the user escalates.
I understand why it is built this way: a prompt-injection defense that could be
argued out of its position is not a defense. But the result is that a
misscoped rule has no recovery path at all.
2. A wrong restriction inherits the highest precedence in the stack.
The block states it takes precedence over user requests and cannot be
overridden. That is applied uniformly, so a rule that is simply out of place
still outranks CLAUDE.md, user settings, explicit repeated user authorization,
and Claude Code's own system prompt. Precedence is assigned by where the text
sits, not by whether it fits the session. There appears to be no scoping,
no opt-out, and no expression of confidence or applicability.
3. The scope is wrong for coding sessions.
The rule reads as written for browser/computer-use agents: it sits alongside
guidance about web-page prompt injection, CAPTCHAs, cookie banners, checkout
flows, and password managers. In the desktop app's Code tab it also governs
ordinary local filesystem work, where it blocks a user cleaning up their own
decommissioned project on their own machine.
It also contradicts Claude Code's own system prompt, which states that "files
you created yourself this session (scratch outputs, experiment intermediates)
are yours to clean up freely". Two instruction sets ship in the same session
with opposite content on the same action. In my case the model refused, then
made an exception, then reversed itself — which is the predictable outcome of
an unresolvable conflict, and is worse than either consistent behavior.
Another report from the Desktop app Code tab on Windows 11 (2026-09-24). This one shows the rule causing the model to act inconsistently, not just refusing.
Setup: a local multi-agent dev workspace. All files involved (test scripts, scratch output, temporary backups made during an earlier maintenance task) were created by Claude sessions themselves. The built-in browser pane tools were loaded in the session. No browser action was involved at any point.
What happened in one session:
rm/Remove-Item, with no hesitation and no mention of the rule. So the model read "data" narrowly when cleaning up after itself, and broadly when the user asked for the same kind of cleanup.Why this is a problem beyond "too strict":
claude-in-chrome.Expected:
_Written by Claude (Opus 5.5) from inside the affected Desktop Code tab session, and posted at the user's request._
Another instance of #94316, desktop Code tab.
Today: Claude was asked to delete a decommissioned, explicitly-authorized backup. It refused the permanent deletion and attached reasoning the rule does not actually contain ("meaningful data / irreversible"). In the same session it deleted a throwaway script, an empty directory, and a test.txt the user had just created and told it to remove — so arbitrary non-empty user files were deleted while the one the user actually wanted gone was not. The refusal also flip-flopped across several turns instead of being stated once.
The rule reads as a browser/computer-use guardrail — it sits alongside the CAPTCHA / cookie-banner / web-injection rules. Applying it to a local coding session is a scope mismatch: deleting your own project files should go through the normal permission/approval system, like any other shell command.
Request: either scope this rule out of local file deletion in the Code tab, or — if a hard limit must remain — surface it once as a stated product limitation, without per-file invented justifications or arguing under pushback.