Anthropic released Claude Code version 2.1.314 with new controls on where the agent can write files and how it handles long, inactive sessions.confirmed The official release notes describe these additions alongside numerous bug fixes for enterprise deployments.
The claim
The update introduces a setting called permissions.blockWritesOutsideWorkingDirectories. According to the release notes, Write, Edit and NotebookEdit actions now refuse any path that sits outside the defined working directories.reported This restriction applies in every permission mode.
The response
The release notes do not cite external feedback or prior incidents driving this change. Instead, the documentation lists the feature as a standard addition to the version, alongside identity provider group filtering for gateway upstreams and guardrail tracing for Bedrock.
The practical upshot
Teams managing Claude Code in production can now enforce stricter file boundaries without custom scripts. The release also addresses several stability issues, including TLS connection failures and model fallbacks on Microsoft Foundry and Amazon Bedrock platforms.
Claims versus evidence
The source material is the official GitHub release page for version 2.1.314. It states that idle compaction activates when a conversation exceeds 200K tokens and remains idle.reported The summary is then used if the prompt cache expires. The claim about write blocking is explicit in the changelog text. There is no independent third-party verification of these behavioral changes in the provided material. The limits acknowledged include the reliance on prompt cache expiration for the summary usage.
Why it matters
- Product teams can enforce security boundaries by blocking writes outside working directories in all modes
- Developers can reduce context window waste by using idle compaction for long conversations
- Administrators can control access by routing only specific IdP groups to gateway upstreams
- Teams using Bedrock can now log which guardrail filters fired without seeing matched text
Topics: Anthropic, Claude Code, AI security, developer tools, context management
Updated
Ask the article
Local keyword search of this article; no generated answers.Which of these is confirmed?
Check the answer
Anthropic released Claude Code version 2.1.314 with new controls on where the agent can write files and how it handles long, inactive sessions.
The matched primary source and announcement wording support the confirmed label.
Did this article give you the evidence you needed?
Your choice stays on this device. No public tally.Questions readers ask
Does Claude Code v2.1.314 prevent editing files outside the project folder?
Yes, the release notes state that Write, Edit and NotebookEdit refuse paths outside working directories in every permission mode.
How does idle compaction work in this version?
Conversations left idle with over 200K tokens are summarized, and that summary is used on the next message if the prompt cache has expired.
Can admins restrict which developers use specific gateway upstreams?
Yes, an optional groups list was added to Claude apps gateway upstreams to filter developers by IdP group membership.
Connected stories
Reading receipt
- Writes refuse paths outside working directories in every permission mode
- Idle conversations exceeding 200K tokens get summarized for next use
- Developers can filter gateway access by IdP group membership
