↓ Skip to main content
  1. Articles/

Claude Code v2.1.328: Auto Mode Reaches Bedrock, Foundry and Google Cloud, and MCP Hooks Can Fail Closed

·1090 words·6 mins·
Florent Clairambault
Author
Florent Clairambault
CTO & software engineer — writing daily about spec-driven development and agentic coding

Version 2.1.328 is the newest entry in the official Claude Code changelog. The raw file is over 1.3 million characters, and I read only its first 100,000. That covers the 2.1.328 entry, but I could not retrieve its full text verbatim. The tool I used returned summaries of the bullets, not the text itself. Treat this as a reading of release notes, not a field test. I have not run this version, and the changelog gives no release date.

Auto mode on the enterprise clouds
#

The most consequential bullet for teams on managed infrastructure: auto mode now works with Claude Opus 4.6 and Sonnet 4.6 on Amazon Bedrock, Google Cloud’s Agent Platform, Microsoft Foundry, and the Claude apps gateway. Interactive sessions with no permission mode set start in auto mode.

Auto mode is the layer that lets an agent keep working without a permission prompt on every tool call. Until now, enterprises routing Claude through their own cloud account were the people most likely to want it and the least likely to get it. They are the ones with long-running tasks, compliance requirements and platform teams that do not want an engineer clicking “allow” forty times an hour.

Two caveats from the changelog itself:

  • The default flips for sessions with no mode set. If your team’s habits assume a prompt-first default, check what your sessions now start in.
  • A related fix says auto mode no longer fails every turn outside Claude Desktop when CLAUDE_CODE_DISABLE_EXPERIMENTAL_BETAS is set behind a gateway that rejects betas. That is a hint that gateway setups were hitting this, so test yours.

I have not verified how the classifier behaves on these providers. The changelog says it works. It does not publish error rates.

MCP hooks can now block on failure
#

mcp_tool hooks accept "onFailure": "block". If the hook’s call fails, the action it guards is blocked, which matches how command and HTTP hooks already behave.

This matters more than it sounds. A hook that guards a dangerous action is a security control. If the hook server is down and the default is to proceed, the control silently vanishes at the moment it is needed. Fail-open is fine for a linter and wrong for “did the secret scanner approve this commit.”

A sketch of what you would set, assuming the usual hook structure in settings.json. I have not tested this exact shape, so check the hooks documentation for field names:

{
  "hooks": {
    "PreToolUse": [
      {
        "matcher": "Bash",
        "hooks": [
          { "type": "mcp_tool", "server": "policy", "tool": "check_command", "onFailure": "block" }
        ]
      }
    ]
  }
}

The decision rule is simple. Anything that enforces policy gets block. Anything that only advises stays fail-open.

A related new variable, CLAUDE_CODE_DISABLE_DEFERRED_TOOL_RESUME, lets a host stop claude -p --resume and --continue from running a tool call that a hook deferred. If you embed Claude Code in your own harness and use deferral to wait for human approval, this closes a path where a resumed session could run the very call you parked.

Warnings for unattended sessions
#

Two new warnings are aimed at people running agents without supervision:

  • A warning appears when a session that skips permission prompts sends a message that a cloud session may hold and drop. Skipping prompts and losing a message is a bad combination, because nobody is watching to notice.
  • /status and claude doctor now flag an OpenTelemetry exporter configured with no endpoint, where its data would likely be lost.

The second is quietly valuable. If you rely on telemetry for cost tracking or audit trails, a misconfigured exporter fails with no error, and you learn about it when the dashboard is empty. Run claude doctor after your next config change.

Self-hosted runner additions
#

The self-hosted runner picks up several flags:

  • --repository-folder names the folder sessions use for a repository at --capacity 1, replacing its path under the base folder.
  • claude self-hosted-runner orchestrator gets --hook-label, which passes chosen session labels to the spawn-runner hook.
  • claude --environment accepts --metadata key=value to label a session for the spawn-runner hook.

Read together, these let a platform team tag sessions and route them to the right runner. That is infrastructure for running many agents at once, not for one developer in one terminal, and it is where agentic tooling is going.

Smaller fixes worth knowing
#

  • CLAUDE_STREAM_IDLE_TIMEOUT_MS now extends the 5-minute connection limit on gateways, custom base URLs and cloud providers. If long-thinking turns were dropping behind a proxy, this is the knob.
  • Zsh no longer stops Bash commands with “not found” errors on words that begin with =, such as echo ====.
  • Automatic compaction rebuilds the system prompt the way /compact does, instead of reusing the session’s earlier one.
  • Token counts on the spinner and for subagents no longer double-count retried replies, miss unstreamed replies, or stall while Claude thinks.
  • Apps that embed Claude Code can enable the policy plugin’s allowManagedModsOnly option, though an administrator’s managed settings still take precedence.

/code-review gets narrower
#

On most models, /code-review now reports only bugs and CLAUDE.md violations. Reuse and cleanup checks moved to /simplify.

This is a sensible split. A review that mixes “this will crash” with “this could be tidier” trains people to skim. Separating them makes the first list worth reading. The cost is that you now have to run two commands to get what one used to give you. If you used /code-review as a cleanup pass, add /simplify to your routine.

What this release says
#

Two of these changes, auto mode on managed clouds and fail-closed hooks, point the same way. Autonomy only scales when the safety controls are as dependable as the agent. Letting the agent run without prompts is half of the job. The other half is making sure the guardrails stop the action when they themselves break.

That is the argument for terminal-native, configurable agents over editor-bound assistants. You can wire the policy layer, the telemetry and the runner routing into your own infrastructure and test each piece. An IDE sidebar with an “accept” button offers none of that.

What I did not check
#

  • I read the changelog only. I did not run 2.1.328 or test any flag.
  • I read the first 100,000 characters of a 1.3 million character file, and the bullets reached me as summaries. Counts and exact wording may differ from the original.
  • The changelog gives no release date or version-to-version diff, so I cannot say what changed relative to 2.1.327 beyond the entry itself.

Sources
#

AI Tools

Claude Code v2.1.327: The Data-Loss Release, Plus Tighter Path and Auto Mode Rules

Claude Code v2.1.327 fixes several silent data-loss bugs (.mcp.json key deletion, /export overwrites, git-ignored files removed on Remote Control stop), refuses some symlinked paths, ignores more package-runner allow rules in auto mode, and says the billed-classifier fallback will be removed. Based on the official changelog only; I have not run this version.

Nov 18, 2026 · 6 min read

AI Tools

Claude Code v2.1.326: Auto Mode Becomes the Fallback, and Credentials Files Get a Guard

Claude Code v2.1.326 (Nov 16) lets Code Mode run alongside agent teams, starts sessions in auto mode when no mode is set and organization policy hasn’t loaded, and blocks file tools from writing to sign-in files like .credentials.json. Based on the official changelog only; I have not run this version.

Nov 17, 2026 · 3 min read

Guides

Claude Code v2.1.301–302: Unattended Retries, a Pickable Auto Mode Classifier, and Fork Subagents Everywhere

Claude Code v2.1.301 (Oct 15) and v2.1.302 (Oct 16) cap how long unattended retries wait on a usage limit, let you choose the client-side auto mode classifier’s model, turn fork subagents on by default outside the terminal, and limit concurrent prompt/agent hooks to 12 per event.

Oct 17, 2026 · 5 min read

Guides

Claude Code v2.1.299: Stricter MCP Allow Rules, Fail-Closed Plugin Hooks, and Idle Compaction

Claude Code v2.1.299 (Oct 14) narrows MCP allow rules to the exact named server, makes plugin hooks that can’t answer refuse the action, stops following redirects on connector proxies, and compacts idle 200K+ token sessions before the one-hour cache expires.

Oct 14, 2026 · 5 min read

AI Tools

Claude Code Hooks Can Now Fail Closed: onFailure: block and What v2.1.293–296 Changed

Claude Code v2.1.295 (Oct 8) added onFailure: “block” for command and HTTP hooks, so a hook that crashes, times out or exits unexpectedly now blocks the action instead of silently allowing it. v2.1.294 also fixed instruction-style prompt hooks that allowed what they were meant to block, while the MCP description limits changed twice in 48 hours.

Oct 10, 2026 · 6 min read