Hooks broken again in v2.0.31 (regression after v2.0.30 fix)
Resolved 💬 9 comments Opened Nov 1, 2025 by Kevthetech143 Closed Jan 18, 2026
Summary
All hooks are non-functional in Claude Code v2.0.31, representing a regression after the successful fix in v2.0.30.
Environment
- Version: 2.0.31 (confirmed via
claude --version) - Platform: macOS Darwin 22.6.0
- Installation: npm global install
Regression Timeline
- ✅ v2.0.25: Hooks working
- ❌ v2.0.27: Hooks broke (issue #10399)
- ❌ v2.0.28-29: Still broken
- ✅ v2.0.30: FIXED (issue #10401 closed Oct 31)
- ❌ v2.0.31: BROKEN AGAIN (regression confirmed Nov 1)
Evidence
Hooks Tested (ALL failed)
- PreCompact - Auto-compaction at ~71K tokens
- Expected: Checkpoint file created in
.checkpoints/ - Actual: No execution, no file created
- Debug log: No entries
- SessionStart - Tested 2x after full restarts
- Expected: Hook fires on session start
- Actual: Silent failure, no debug log entries
- PreToolUse/PostToolUse - Tested with Bash tool
- Expected: Hook execution after tool use
- Actual: No execution logged
- UserPromptSubmit - Tested with user prompts
- Expected: Hook fires on prompt submission
- Actual: Silent failure
Debug Evidence
- Debug log file:
/tmp/claude-hooks-debug.log - Last entry timestamp: Nov 1, 14:40 (before testing)
- No new entries after: Auto-compaction, session restarts, tool usage
- Manual script execution: ✅ Works perfectly
- Configuration: ✅ Verified correct per schema
Configuration Example
{
"PreCompact": [
{
"matcher": "manual|auto",
"hooks": [
{
"type": "command",
"command": "/path/to/hook.sh",
"description": "Checkpoint system"
}
]
}
],
"SessionStart": [
{
"hooks": [
{
"type": "command",
"command": "/path/to/session-start.sh",
"description": "Session initialization"
}
]
}
]
}
Related Issues
- #10399 - Original report (v2.0.27 broke hooks)
- #10401 - Fix confirmed in v2.0.30 (now regressed)
- #10450 - Windows hook failures
CHANGELOG Analysis
v2.0.31 changes:
- Windows native installation
- Vertex web search
- Bug fixes for subagent MCP naming
- Bug fixes for /compact command
- NO mention of hook changes
This suggests the regression was unintentional - likely a merge conflict or accidental revert of the v2.0.30 fix.
Impact
- Scope: All hook types broken (lifecycle, event, tool)
- Platforms: macOS confirmed, likely Windows/Linux
- Users: Multiple users affected (29+ open hook issues since Oct 25)
- Workflows: Checkpoint automation, event-driven workflows, monitoring systems
Workarounds
- Launch with debug flag:
claude --debug hooks - Downgrade to v2.0.30:
npm install -g @anthropic-ai/claude-code@2.0.30
Request
Please prioritize this as a REGRESSION - the issue was fixed in v2.0.30 and broke again within 24 hours. Suggest comparing hook initialization code between v2.0.30 (working) and v2.0.31 (broken) to identify what changed.
Thank you for the quick fix in v2.0.30 - hoping for similar resolution for this regression.
This issue has 9 comments on GitHub. Read the full discussion on GitHub ↗