anthropic Claude Code Releases · · 2.1.212

Claude Code v2.1.212: New /fork behavior, background tasks, and fixes

sdkaideprecationengineermediaenergy
patch

This update for Claude Code introduces a new behavior for `/fork`, copying conversations to background sessions while users continue working. It also adds features like automatic mode reset, session limits for web searches and subagent spawns, and background processing for long-running MCP tool calls. Numerous bug fixes address issues with plan mode, worktree creation, tool failures, and UI elements, improving overall stability and user experience for engineers interacting with code.

  • /fork now copies conversation to a new background session
  • Added 'claude auto-mode reset' command
  • Session limits introduced for WebSearch and subagent spawns
  • Long-running MCP tool calls automatically moved to background
  • /resume command now opens a picker for past sessions
Enhancements (5)
  • /fork now copies conversation to a new background session

    The `/fork` command now copies the current conversation into a new background session, creating its own row in `claude agents`, while the user continues their current work. The in-session subagent it previously launched is now handled by `/subtask`.

  • Added 'claude auto-mode reset' command

    A new command, `claude auto-mode reset`, has been added to restore the default auto-mode configuration. This command includes a confirmation prompt, which can be bypassed by passing `--yes`.

  • Session limits introduced for WebSearch and subagent spawns

    To prevent runaway loops, session-wide limits have been added for WebSearch tool calls (default 200, tunable via `CLAUDE_CODE_MAX_WEB_SEARCHES_PER_SESSION`) and subagent spawns (default 200, override with `CLAUDE_CODE_MAX_SUBAGENTS_PER_SESSION`). The `/clear` command resets the subagent budget.

  • Long-running MCP tool calls automatically moved to background

    MCP tool calls exceeding 2 minutes will now automatically move to the background, ensuring the session remains usable. The threshold can be configured or disabled via `CLAUDE_CODE_MCP_AUTO_BACKGROUND_MS`.

  • /resume command now opens a picker for past sessions

    Typing `/resume` in the agent view now displays a picker for past sessions, including those deleted from the list, allowing users to resume their selection as a background session.

Fixes (1)
  • Fixed plan mode auto-running file-modifying Bash commands without prompt

    Plan mode no longer auto-runs file-modifying Bash commands like `touch` or `rm` without first requiring a permission prompt or SDK `canUseTool` callback.

Read the original announcement →

https://github.com/anthropics/claude-code/releases/tag/v2.1.212

Related releases