v2.1.89
Claude CodeSummary
This release introduces significant new capabilities for headless sessions with deferred permission handling and enhanced tool usage hooks. Numerous bugs have been resolved across file operations, history persistence, and tool execution, particularly for Windows and large file handling. Quality of life improvements include better tool summaries, updated PowerShell guidance, and disabling default thinking summaries.
New Features
- Added "defer" permission decision to PreToolUse hooks, allowing headless sessions to pause and resume tool calls for re-evaluation.
- Enabled flicker-free alt-screen rendering via the CLAUDE_CODE_NO_FLICKER=1 environment variable for virtualized scrollback.
- Introduced PermissionDenied hook that fires after auto mode classifier denials, allowing the model to retry by returning {retry: true}.
- Added named subagents to @ mention typeahead suggestions.
- Enabled non-blocking MCP connection mode using MCP_CONNECTION_NONBLOCKING=true for -p mode, and bounded server connections to 5s.
- Auto mode denied commands now show a notification and are visible in /permissions → Recent tab for retrying.
- Introduced /buddy for April 1st, a small creature that watches you code.
Bug Fixes
- Fixed Edit(//path/**) and Read(//path/**) allow rules to correctly check the resolved symlink target instead of just the requested path.
- Fixed voice push-to-talk activation issues with modifier-combo bindings and resolved WebSocket upgrade rejections in voice mode on Windows.
- Fixed Edit/Write tools incorrectly doubling CRLF and stripping Markdown hard line breaks (two trailing spaces) on Windows.
- Fixed StructuredOutput schema cache bug that caused approximately 50% failure rate when using multiple schemas.
- Fixed memory leak where large JSON inputs were retained as LRU cache keys during long-running sessions.
- Fixed crash occurring when removing a message from very large session files (over 50MB).
- Fixed LSP server zombie state after a crash; the server now restarts on the next request instead of failing until the session restarts.
- Fixed prompt history entries containing CJK or emoji being silently dropped when they fell on a 4KB boundary in ~/.claude/history.jsonl.
- Fixed /stats undercounting tokens by excluding subagent usage and losing historical data beyond 30 days when the stats cache format changed.
- Fixed -p --resume hangs when deferred tool input exceeds 64KB or lacks a deferred marker, and fixed -p --continue not resuming deferred tools.
- Fixed claude-cli:// deep links failing to open on macOS.
- Fixed MCP tool errors truncating to only the first content block when the server returned multi-element error content.
- Fixed skill reminders and other system context being dropped when sending messages with images via the SDK.
- Fixed PreToolUse/PostToolUse hooks receiving file_path as a relative path instead of the documented absolute path for Write/Edit/Read tools.
- Fixed autocompact thrash loop by detecting when context refills immediately after compacting three times and stopping with an actionable error.
- Fixed prompt cache misses in long sessions caused by tool schema bytes changing mid-session.
- Fixed nested CLAUDE.md files being re-injected dozens of times in long sessions that read many files.
- Fixed --resume crash when the transcript contained a tool result from an older CLI version or an interrupted write.
- Fixed misleading "Rate limit reached" message when the API returned an entitlement error; now shows the actual error.
- Fixed hooks if condition filtering not matching compound commands (e.g., ls && git push) or commands with env-var prefixes.
- Fixed collapsed search/read group badges duplicating in terminal scrollback during heavy parallel tool use.
- Fixed notification invalidates not clearing the currently-displayed notification immediately.
- Fixed prompt briefly disappearing after submit when background messages arrived during processing.
- Fixed truncation of Devanagari and other combining-mark text in assistant output.
- Fixed rendering artifacts on main-screen terminals after layout shifts.
- Fixed voice mode failing to request microphone permission on macOS Apple Silicon.
- Fixed Shift+Enter submitting instead of inserting a newline on Windows Terminal Preview 1.25.
- Fixed periodic UI jitter during streaming in iTerm2 when running inside tmux.
- Fixed PowerShell tool incorrectly reporting failures when commands like git push wrote progress to stderr on Windows PowerShell 5.1.
- Fixed potential out-of-memory crash when the Edit tool was used on very large files (>1 GiB).
Improvements
- Improved collapsed tool summary to show "Listed N directories" for ls/tree/du instead of "Read N files".
- Improved Bash tool to warn when a formatter/linter command modifies files previously read, preventing stale-edit errors.
- Improved @-mention typeahead to rank source files above MCP resources with similar names.
- Improved PowerShell tool prompt with version-appropriate syntax guidance (5.1 vs 7+).
- Changed Edit tool to work on files viewed via Bash with sed -n or cat, without requiring a separate Read call first.
- Changed hook output over 50K characters to be saved to disk with a file path + preview instead of being injected directly into context.
- Changed cleanupPeriodDays: 0 in settings.json to be rejected with a validation error instead of silently disabling transcript persistence.
- Changed thinking summaries to no longer be generated by default in interactive sessions; set showThinkingSummaries: true to restore.
- Preserved task notifications when backgrounding a running command with Ctrl+B.
- PowerShell tool on Windows now prompts for external-command arguments containing both a double-quote and whitespace due to PS 5.1 hardening.
- /env now applies to PowerShell tool commands (previously only affected Bash).
- /usage now hides redundant "Current week (Sonnet only)" bar for Pro and Enterprise plans.
- Image paste no longer inserts a trailing space.
- Pasting !command into an empty prompt now enters bash mode, matching typed ! behavior.