You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix(hooks): don't emit invalid permissionDecision 'defer' — it swallows AskUserQuestion
The PreToolUse question-preference-hook returned
`{"permissionDecision":"defer"}` to mean "no opinion, let the permission
flow continue". That value is not in Claude Code's PreToolUse schema, which
accepts only `allow` / `deny` / `ask`.
As of Claude Code 2.1.14 the unrecognized value is interpreted as "defer the
tool call": the call is dropped and recorded as a `hook_deferred_tool`
attachment. For AskUserQuestion this means the question widget never renders
— the user sees nothing at all and the agent is left waiting. Observed in a
real transcript: hook_success with `"permissionDecision":"defer"`, then
`hook_deferred_tool`, then the user typing "questions are not loading".
Because the defer path is the default for every non-auto-decidable question
(no preference set, marker missing, always-ask, one-way door safety
override), this broke AskUserQuestion for essentially all users, not just
those with plan-tune preferences configured.
Fix: omit `permissionDecision` entirely in defer(). That is the correct
"no opinion" signal — normal permission flow continues and
`additionalContext` (the memory-cache injection) is still delivered.
The deny paths (never-ask auto-decide, Conductor prose redirect) are
untouched and still enforce.
Tests updated to assert `permissionDecision` is undefined on the defer path
rather than the string 'defer'. 51 pass / 0 fail across
question-preference-hook, memory-cache-injection and gstack-question-log.
0 commit comments