Follow Discord
Sweep 20 Nov 2026 · 19:55Z Build v2.1.330 547 read Stable v2.1.323 Latest v2.1.330 Next v2.1.330 Feeds RSS JSON llms.txt llms-full.txt Unofficial

Claude Code v2.1.328 ·

Hooks that rewrite a tool's result badly now cause an error for some tools

For some tools, a PostToolUse hook that rewrites a result into the wrong shape now produces an error instead of being silently ignored

You'll notice Improvements
JSON All of v2.1.328
You'll noticeTier: how much it should matter to you
3Useful: my rating, 1 to 5
2Signal: worth watching, 1 to 5
HooksArea: what it touches
ImprovementsKind: in v2.1.328,
ImprovementsSection of the release

Unclear Which tools get the new check is not stated.

What

A PostToolUse hook is a command you set up to run after a tool call succeeds. A tool call is one action Claude takes, such as reading a file or running a command. A hook of this kind can replace the result the tool returned.

Before, a replacement result was used only if it matched the shape the tool's output is supposed to have. If it did not match, it was dropped without any message. For some tools, Claude Code now checks the result after all hooks have run, and handles a bad result like this:

  • A managed PostToolUse hook (one set by an administrator) that returns a result in the wrong shape makes the tool call fail with an error naming the tool.
  • A hook that replaces the result with a list whose items are not all content blocks makes the call fail with a different error.
  • In other cases, Claude Code falls back to the tool's original output.
Why

People who write hooks now get a clear error when a rewrite is wrong, instead of having it quietly ignored.

Read from
Names in the bundlePostToolUse
Since it was published

The entry above is what we published on the day. These lines were added later, as Anthropic's own pages caught up, and they sit beside the original rather than replacing it.

Confirmed since Anthropic's documentation has since written up PostToolUse, on Changelog. * Changed `PostToolUse` hooks in Claude Code's managed settings to no longer run for tool calls refused before the tool started, so logs that these hooks write lose those entries. cowork/changelog see the edit
How sure we are
Something disagreesSomething we can check disagrees with this entry, or the writer said they could not settle it.
The writer flagged doubtWhich tools get the new check is not stated.
Anthropic's documentation agreesAnthropic's documentation has since written up PostToolUse, on Changelog.
Anthropic's release notes agreeChanged managed PostToolUse hooks to no longer fire for calls refused before they ran: no log entry, rewrite, block or stop there…

See this entry in the whole of v2.1.328 →

Feedback