Follow Discord
Sweep 22 Oct 2026 · 21:04Z Build v2.1.309 528 read Stable v2.1.308 Latest v2.1.309 Next v2.1.309 Feeds RSS JSON llms.txt llms-full.txt Unofficial

Claude Code v2.1.309 ·

Clearer guidance when a hook's command is set up the wrong way

Hook error messages now explain how to split a command into "command" and "args", or mark it as PowerShell, including when Git Bash is missing

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

What

A hook is a command Claude Code runs automatically at set points while it works. You configure it in your settings. This release improves the messages shown when a hook's command is set up in a way Claude Code cannot run.

  • When a hook is blocked because Git Bash was not found, the message is now tailored to the hook. Git Bash is the shell many Windows setups use to run hook commands. The message now says that only exit code 0 or 2 counts as the hook's verdict. Before, it only said the hook did not set "shell" to "powershell".
  • PowerShell hooks are told to finish with exit code 0 or 2, or to set "onFailure" to "continue".
  • Other hooks are told to put the program in "command" and its arguments in "args", with "onFailure" set to "block".
  • A new error message says to put the program in "command" and its arguments in "args", or to set "shell" to "powershell" on a command written for PowerShell. It appears when a whole command line is given where a program and its arguments are expected.

Why

On Windows especially, a hook can fail for reasons that are hard to work out from a generic message. These messages tell you which settings to change to make the hook run.

See this entry in the whole of v2.1.309 →

Feedback