Under the hoodTier: how much it should matter to you
3Useful: my rating, 1 to 5
3Signal: worth watching, 1 to 5
SDKArea: what it touches
New FeaturesKind: in v2.1.335,
New FeaturesSection of the release
What
When Claude runs a shell command through the Bash tool and the command fails, Claude Code can now pass along the files that command changed. A host is the program that embeds Claude Code and draws its screen, such as an IDE extension or an app built on the SDK (the kit for building programs on top of Claude Code). Here is how the change is passed along:
bash_edit_diff is a new internal field in the SDK message format that holds the files a failed Bash command changed.
setHostDrawsBashEditDiff is a new host option. The field is sent only when the host asks for it at start.
editDiff is now carried on the Bash tool's result.
bashEditDiff is now added to errored tool results that have an editDiff. A new check decides this, and by default it always allows it.
The same release also changes how tools run. A running tool now holds a cleanup stack (AsyncDisposableStack), and untilHooksEnd is passed into the tool's context. A hook is a user-defined script that Claude Code runs at set points, and this lets a tool stay open until the hooks running alongside it have finished.
Why
A command that fails partway can still have edited files. Hosts that opt in can now show those edits instead of only the error. Hook timing around tool runs may also differ slightly.