{"version":"2.1.265","anchor":"new-hook-timing-guard-message-for-classic-hooks-calling-turn","canonical_anchor":"new-hook-timing-guard-message-for-classic-hooks-calling-turn","heading":"Clearer warning for classic hooks that risk deadlocking on a turn","tier":"notice","area":"Hooks","scope":null,"heads_up":null,"url":"https:\/\/changelogs.core-directive.com\/v\/2.1.265\/e\/new-hook-timing-guard-message-for-classic-hooks-calling-turn","release_url":"https:\/\/changelogs.core-directive.com\/v\/2.1.265","markdown":"### Clearer warning for classic hooks that risk deadlocking on a turn\n\nClaude Code now explains and prevents a deadlock when a classic hook other than SessionStart, Setup, or SessionEnd tries to wait on the turn it's holding\n\n**What**\n\nHooks are scripts that run at certain points in a session (for example, when a session starts or ends). Claude Code has \"classic\" hooks (`classic.*`) for these events, plus other hook-like calls such as `command.run` and `tool.call`.\n\nA new check now catches the case where a call from a `classic.*` hook \u2014 other than `SessionStart`, `Setup`, or `SessionEnd` \u2014 would block waiting on the very turn that hook is currently holding. Previously this could silently deadlock. Now it produces a specific, clear error explaining the problem and suggesting the call be made from `turn.complete` instead. This check is wired in as the fallback case alongside the same checks already used for `command.run`, `tool.call`, and similar calls.\n\n**Why**\n\nThis turns a confusing hang into an understandable error message, and tells you exactly how to fix it (move the call to `turn.complete`), so hook authors aren't left guessing why their hook froze.\n\n- Area: Hooks\n- Names: `turn.complete`\n- Tier: You'll notice\n- Useful: 2\/5\n- Signal: 1\/5"}