Change8

v2.1.251

Claude Code
6 features40 fixes7 improvementsbedrockclidesktophooksmcpsdkvertexvscode

Summary

This release introduces new hook events for model switches and live streaming of subagent tool calls to Remote Control clients. It also includes significant improvements to session management, file tool security, and error handling across various tools and integrations, alongside numerous bug fixes for a more stable experience.

New Features

  • Added hook events `PreModelSwitch` and `PostModelSwitch` to allow blocking, confirming, or annotating model switches.
  • Introduced live streaming of foreground subagent tool calls and results to Remote Control clients.
  • Added a Spend limit bar to `/usage` and a `rate_limits.spend_limit` status line field for developers using Claude apps gateway with spend limits.
  • Added a per-session prompt-cache line to `/cost` (hit ratio, misses, tokens re-cached, warm/cold) and a matching `prompt_cache` object for status line scripts.
  • Added `attach`, `logs`, `stop`, `respawn`, and `rm` commands to `claude --help` for easier session management.
  • Enabled replying to messages delivered by Claude Desktop from other sessions, now routing `SendMessage` correctly.

Bug Fixes

  • Fixed file tools (Read, Write, Edit) from incorrectly accessing files outside the approved location when following symlinks.
  • Fixed plugin commands declared in marketplace entries from pointing outside the plugin directory, preventing path-traversal vulnerabilities.
  • Fixed project settings from allowing the enablement of detailed beta tracing or raw API body logging, and bypassing OTLP collector pinning.
  • Fixed the Workflow tool from incorrectly reading and quoting `scriptPath` values outside the session's readable scope.
  • Fixed Grep and Glob from not applying `Read(...)` deny rules to files accessed through symlinked search paths.
  • Fixed conversations from getting stuck on 'text content blocks must be non-empty' errors when the model produced only thinking.
  • Fixed the first launch on a fresh install from defaulting to default mode instead of auto mode for accounts configured for auto mode startup.
  • Fixed Opus 5 requests failing with an 'effort not supported when thinking is disabled' error by sending effort as `high` in that scenario.
  • Fixed TUI lag with many parallel subagents by replacing per-second progress ticks instead of piling them up.
  • Fixed agent teams so that a teammate's final answer now correctly reaches the team lead.
  • Fixed background subagents from being unable to reply to messages from unnamed sibling or parent agents.
  • Fixed managed-settings `disableAutoMode` from not moving an already-running auto-mode session back to default mode when arriving mid-session.
  • Fixed a tip about switching to Opus 1M for more context from appearing when the current Opus model already had a 1M context window.
  • Fixed Claude apps gateway sessions from incorrectly treating stored Anthropic profiles as active.
  • Fixed cloud sessions from incorrectly advising the model had changed when the host was only setting the initial model.
  • Fixed Remote Control from reporting a failure when an organization policy disables it, now showing a quiet notice instead.
  • Fixed `/mcp reconnect` on Remote Control from showing a generic error instead of the actual remedy when a server was disabled.
  • Fixed `--input-format stream-json` from losing assistant tool call results when client-injected calls were sent without a message id.
  • Fixed session transcripts from being silently overwritten when a directory change relocated a session onto an existing same-ID transcript.
  • Fixed background sessions and subagents from being unable to edit files inside a git worktree they created.
  • Fixed background sessions from occasionally starting without plugin skills when the plugin marketplace was refreshing.
  • Fixed text selection in opened background sessions inside tmux over SSH from copying to the tmux buffer correctly.
  • Fixed SDK and cloud sessions from hanging indefinitely when an SDK MCP server's handshake acknowledgment was lost, now timing out.
  • Fixed self-hosted runner from leaving stuck Bash tool processes running after a session was force-stopped.
  • Fixed `/usage-credits` for Team and Enterprise members with a $0 org limit from offering to ask the admin instead of stating a cap was reached.
  • Fixed `--worktree --tmux` with a gitlab.com merge-request number from trying a GitHub-style fetch instead of fetching the GitLab ref directly.
  • Fixed Ctrl+G from failing with an 'Emacs quit unexpectedly' error in background sessions for editors opening `/dev/tty`.
  • Fixed startup crashes or broken settings updates caused by an `additionalDirectories` entry containing a null byte.
  • Fixed the MCP server menu's copy shortcut from incorrectly claiming success instead of stating how the sign-in URL was copied.
  • Fixed italic text rendering as highlighted blocks in GNU screen and tmux sessions using a `screen` terminal type.
  • Fixed `claude mcp add --header` and `claude mcp add-json` help text from naming the wrong transports.
  • Fixed `claude ultrareview` and `/ultrareview` from waiting the full 30 minutes when the cloud session failed to start, now stopping early.
  • Fixed Bash permission checks from auto-approving commands that assign arithmetic expressions to integer shell variables, now prompting for approval.
  • Fixed backgrounded sessions from losing exported Vertex/Bedrock gateway variables, causing requests to fail.
  • Fixed `claude --bg --model fable` on Max plans from stopping to ask for usage credits when the interactive session still had allowance.
  • Fixed the one-time 'make auto mode your default' offer from appearing in unattended sessions where it could be accidentally accepted.
  • Fixed the managed-settings approval prompt from re-appearing after re-signing in when settings were unchanged.
  • Fixed disabled `/bug` and `/share` from incorrectly reporting that `/feedback` was disabled, and now correctly hides `/feedback` suggestions.
  • Fixed cloud session creation from advising GitHub setup after a transient GitHub connection failure, now suggesting a retry.
  • Fixed background sessions and their subagents from being unable to edit files inside a git worktree they created with `git worktree add`.

Improvements

  • Improved CPU usage during turns in interactive sessions by reducing redundant UI re-renders.
  • Reduced install size by approximately 5 MB.
  • Improved cloud session error reporting when a network proxy drops a connection during a Bash command, now naming the host and reason.
  • Improved `/schedule` to clarify that MCP servers configured in Claude Code cannot be attached to cloud routines.
  • Improved framing of messages from your own subagents to correctly identify them as workers within the session.
  • Improved the prompt placeholder to read 'Message @name…' when viewing a background subagent or fork transcript.
  • Improved sanitization of MCP server names in error messages.

Claude Code Documentation