PR #786 changed the save and precompact hooks from "decision": "block" to "decision": "allow" to stop the agent from writing in chat. The intent was right but "allow" isn't a valid value for the top-level decision field.
The fix is "allow" → "approve".
Update: "approve" isn't valid here either — it's a deprecated PreToolUse-only alias (maps to "allow" in hookSpecificOutput.permissionDecision). The top-level decision field only recognizes "block". To not block, you return empty JSON ({}).
Affected files:
hooks/mempal_save_hook.sh (line 159)
hooks/mempal_precompact_hook.sh (line 74)
Fix: Replace the full JSON output block with {} when not blocking. Only use {"decision": "block", "reason": "..."} when the hook actually needs to prevent the action.
Note: PR #863 already caught this — mvalentsev replaced the invalid {"decision": "allow", ...} with {} in hooks_cli.py. The standalone bash hooks still need the same treatment.
Related: #856, #858 (report compaction symptoms that may stem from this)
PR #786 changed the save and precompact hooks from
"decision": "block"to"decision": "allow"to stop the agent from writing in chat. The intent was right but"allow"isn't a valid value for the top-leveldecisionfield.The fix is"allow"→"approve".Update:
"approve"isn't valid here either — it's a deprecated PreToolUse-only alias (maps to"allow"inhookSpecificOutput.permissionDecision). The top-leveldecisionfield only recognizes"block". To not block, you return empty JSON ({}).Affected files:
hooks/mempal_save_hook.sh(line 159)hooks/mempal_precompact_hook.sh(line 74)Fix: Replace the full JSON output block with
{}when not blocking. Only use{"decision": "block", "reason": "..."}when the hook actually needs to prevent the action.Note: PR #863 already caught this — mvalentsev replaced the invalid
{"decision": "allow", ...}with{}inhooks_cli.py. The standalone bash hooks still need the same treatment.Related: #856, #858 (report compaction symptoms that may stem from this)