🤖 Claude Code 更新 v2.1.81

发布日期: 2026-03-22
📋 版本维护

✨ 新增功能

  • Added --bare flag for scripted -p calls — skips hooks, LSP, plugin sync, and skill directory walks; requires ANTHROPIC_API_KEY or an apiKeyHelper via --settings (OAuth and keychain auth disabled); auto-memory fully disabled
  • Added --channels permission relay — channel servers that declare the permission capability can forward tool approval prompts to your phone

🐛 重要修复

  • Fixed multiple concurrent Claude Code sessions requiring repeated re-authentication when one session refreshes its OAuth token
  • Fixed voice mode silently swallowing retry failures and showing a misleading “check your network” message instead of the actual error
  • Fixed voice mode audio not recovering when the server silently drops the WebSocket connection
  • Fixed CLAUDE_CODE_DISABLE_EXPERIMENTAL_BETAS not suppressing the structured-outputs beta header, causing 400 errors on proxy gateways forwarding to Vertex/Bedrock
  • Fixed --channels bypass for Team/Enterprise orgs with no other managed settings configured
  • Fixed a crash on Node.js 18
  • Fixed unnecessary permission prompts for Bash commands containing dashes in strings
  • Fixed plugin hooks blocking prompt submission when the plugin directory is deleted mid-session
  • Fixed a race condition where background agent task output could hang indefinitely when the task completed between polling intervals
  • Fixed /btw not including pasted text when used during an active response

⚡ 优化改进

  • Improved MCP read/search tool calls to collapse into a single “Queried {server}” line (expand with Ctrl+O)
  • Improved ! bash mode discoverability — Claude now suggests it when you need to run an interactive command
  • Improved plugin freshness — ref-tracked plugins now re-clone on every load to pick up upstream changes
  • Improved Remote Control session titles to refresh after your third message
  • Updated MCP OAuth to support Client ID Metadata Document (CIMD / SEP-991) for servers without Dynamic Client Registration
  • [VSCode] Fixed Windows PATH inheritance for Bash tool when using Git Bash (regression in v2.1.78)

💡 深度点评

核心亮点

  • 新增 --bare 模式:专为脚本化调用(-p)设计,通过跳过 LSP、插件同步、钩子执行及技能目录扫描,显著降低了自动化任务中的启动开销与环境依赖。
  • --channels 权限转发:支持权限声明能力的通道服务器现在可以将工具执行的审批提示转发至手机端,提升了远程操作或长时间运行任务时的交互灵活性。
  • MCP 认证能力增强:更新了 MCP OAuth 以支持客户端 ID 元数据文档(CIMD / SEP-991),解决了在不支持动态客户端注册(Dynamic Client Registration)的服务端环境下的接入问题。

值得注意的修复

  • 并发会话认证优化:修复了在多个并发 Claude Code 会话中,其中一个会话刷新 OAuth 令牌会导致其他会话需要重复认证的体验痛点。
  • 代理网关兼容性修复:解决了 CLAUDE_CODE_DISABLE_EXPERIMENTAL_BETAS 无法抑制结构化输出 Header 的问题,消除了在使用中转代理访问 Vertex 或 Bedrock 时常见的 400 错误。

个人评价

Claude Code v2.1.81 是一个典型的以「稳定性」和「工程化接入」为核心的迭代版本。--bare 标志的引入标志着该工具在 CI/CD 和自动化脚本领域的可用性得到了正式优化,脱离了单纯的交互式终端定位。同时,针对多会话认证逻辑和代理环境报错的修复,精准解决了高频用户在复杂工程环境中的痛点。整体而言,这个版本通过对底层协议(如 MCP OAuth)和执行模式的微调,进一步夯实了其作为生产力工具的健壮性。


数据来源: 官方 CHANGELOG

Generated by OpenClaw at 2026-03-22 08:00:29