Claude Code 2.1.312
39changes- Add oidc.user_id_claim so enterprise gateways can map a custom id_token claim to each user.
- Add an effort level to the model picker for routines that run in the cloud.
- Stop Claude from overwriting a large CLAUDE.md, rules file or @-included file it only partly read.
- Fix managed settings and organization policy not being fetched after signing in from the VS Code extension.
- Use the shorter system prompt by default for model names Claude Code doesn't recognize on Bedrock, Vertex, Foundry and Mantle.
New features
4Configure OIDC user id claim
Added oidc.user_id_claim to the Claude apps gateway, to identify people by an id_token claim other than sub, such as Microsoft Entra ID's oid
[Cloud sessions] Add effort level to routines
Added an effort level to the model picker when you create or edit a routine that runs in the cloud
▤ In the docsMore changes (2) Fewer changes
Click to send queued messages
Added click to send: in fullscreen, clicking the "to send now" hint under a queued message sends it right away, as its key does
[Cloud sessions] Add Bash editor for setup script
Added a Bash editor with colors, line numbers and a Copy button to the setup script box in cloud environment settings
Improvements
13Shorter prompt for unrecognized model names
Changed Bedrock, Vertex, Foundry and Mantle to use the shorter system prompt for model names Claude Code doesn't recognize, such as custom deployment names and inference profile ARNs, even when they front Sonnet or Haiku; set CLAUDE_CODE_SIMPLE_SYSTEM_PROMPT=0 to keep the full prompt
Extend model switch to unknown names
Changed automatic model switches after a flagged message to also cover model names Claude Code doesn't recognize, such as custom deployment names; set CLAUDE_CODE_DISABLE_REFUSAL_FALLBACK=1 to turn them off
Cap concurrent hook executions
Changed prompt and agent hooks to run at most 24 at a time per session, sub-agents included, plus at most 12 that have waited longer than their event's timeout; a timeout under 1 second now counts as 1 second
More changes (10) Fewer changes
Improve mid-task effort change note
Improved the prompt's effort indicator: a change made mid-task now says it may wait for your next message, and the note clears when it no longer applies
Improve cloud WebFetch DNS errors
Improved WebFetch errors in cloud sessions: a host that does not resolve is now explained as possibly outside the allowed network domains, so Claude names the host to allow
Rename session limit to 5-hour limit
Changed usage limit messages to call the 5-hour window the "5-hour limit" instead of the "session limit"
Get cloud session names from server
Changed cloud sessions started from the CLI to get their names and branch names from the server
Let autoCompactWindow lower env setting
Changed a subagent's autoCompactWindow to lower the window set by CLAUDE_CODE_AUTO_COMPACT_WINDOW, where it had no effect before; it still never raises that window
Report real plugin MCP server names
Changed OpenTelemetry mcp_server.name to report the real name of fixed-URL remote MCP servers declared by plugins from the official Anthropic marketplace, instead of custom
Stop sending safety_event telemetry
Changed Claude Code to stop sending the claude_code.safety_event OpenTelemetry event
[VSCode] Show reset time and 5-hour limit
Changed usage limit resets to show a clock time ("Resets at 3:10 PM") and to say "5-hour limit"
[Cloud sessions] Show repo-add step as a table
Improved the step shown when Claude adds a repository to a cloud session: opening it now shows a short table of what happened instead of raw JSON
[Claude Tag] Clarify Slack retry notices
Improved Claude Tag's retry notice in Slack to name the model in use, or say rate limits were hit, instead of a generic API error
Bug fixes
22Fix overwrite of large memory files
Fixed Claude overwriting a very large CLAUDE.md, rules file or @-included file in a subdirectory after seeing only its start; Write now asks Claude to read it all or edit in place
Fix policy fetch after VS Code sign-in
Fixed managed settings and organization policy not being fetched for the rest of the session after signing in from the VS Code extension
More changes (20) Fewer changes
Fix skills lost after cd deeper
Fixed per-directory and paths: skills not being found after a Bash cd deeper into a git repository
Fix lost reply on second resume
Fixed a rare case where the first reply after resuming a session in the terminal could be missing the next time the session was resumed
Fix bad command name blocking loading
Fixed a command with an invalid name stopping all commands from loading, which could leave claude -p with no output
Fix PDF read failure during cleanup
Fixed the Read tool sometimes failing on PDF pages with "pdftoppm failed: Could not write image" when the clean-up of old session files ran at the same time
Fix premature effort level display
Fixed the spinner, OpenTelemetry effort values and transcripts naming a newly picked effort level during a task before the model applied it; they now show the level in force
Fix /model and /effort cache warning
Fixed the /model and /effort cache warning saying the re-read waits for your next message; a change made while Claude is working can trigger it sooner
Fix false waiting-on-you session status
Fixed some sessions showing as waiting on you when the last message only mentioned items waiting on you mid-sentence
Fix stale input text on relaunch
Fixed agent view restoring input text on the next launch after it was cleared with Ctrl+C just before exiting
Fix agent view reopening in shell mode
Fixed agent view reopening in shell mode after exiting with Ctrl+D from an empty ! input
Fix vim d, c, y with large gj/gk count
Fixed vim mode d, c and y with a gj or gk count larger than the lines left deleting or copying text; like Vim, they now only move the cursor
Fix /verify showing long description
Fixed /verify showing a long description meant for Claude in /help and the / command menu instead of a short one
[VSCode] Explain startup settings failure
Fixed sessions ending on a bare exit code when your organization's settings couldn't be loaded or were refused at startup; the tab now says why and offers Retry or Sign in again
[Cloud sessions] Fix duplicate resend after failure
Fixed resending an unchanged message after a failed send in a cloud session sometimes running it twice
[Cloud sessions] Show creation errors inside dialog
Fixed a failed cloud environment creation showing its error only as a toast outside the open dialog; it now appears inside the dialog
[Cloud sessions] Fix Edit menu not opening dialog
Fixed Edit in a routine's menu on the Routines page going to the routine's page without opening its edit dialog
[Remote Control] Fix stale working status
Fixed an unarchived Remote Control session showing as working until a computer reconnected; it now shows as idle
[Claude Tag] Fix settings reset on channel ID change
Fixed a Claude Tag channel's on/off switch and agent settings falling back to workspace defaults when an older private Slack channel goes public and gets a new ID
[Claude Tag] Fix no-reply on None network access
Fixed Claude in Slack not replying in channels whose environment has network access set to None
[Claude Tag] Fix file posted to wrong thread
Fixed Claude in Slack sometimes posting a file in the wrong thread when it was answering in another thread of the same channel
[Code Review] Fix review on stale commit
Fixed Code Review reviewing an outdated commit, or none at all, when GitHub delivered a push event late; it now reviews the pull request's current commit