[BUG] UserPromptSubmit hook does not anymore trigger with an initial prompt as argument
Resolved 💬 3 comments Opened Jan 10, 2026 by raine Closed Jan 15, 2026
Preflight Checklist
- [x] I have searched existing issues and this hasn't been reported yet
- [x] This is a single bug report (please file separate reports for different bugs)
- [x] I am using the latest version of Claude Code
What's Wrong?
Before v2.0.77, until v2.0.76, the UserPromptSubmit used to trigger when starting claude with a prompt interactively.
Hook
{
"hooks": {
"UserPromptSubmit": [
{
"hooks": [
{
"type": "command",
"command": "exit 1"
}
]
}
]
}
}
% claude 'test'
▐▛███▜▌ Claude Code v2.1.3
▝▜█████▛▘ Opus 4.5 · Claude Max
▘▘ ▝▝ ~/code/workmux
❯ test
⎿ Interrupted · What should Claude do instead?
Hook does not trigger anymore.
What Should Happen?
% claude 'test'
* ▐▛███▜▌ * Claude Code v2.0.76
* ▝▜█████▛▘ * Opus 4.5 · Claude Max
> test
⎿ UserPromptSubmit hook error
⎿ Interrupted · What should Claude do instead?
Hook triggers correctly
Steps to Reproduce
Use a hook like this:
{
"hooks": {
"UserPromptSubmit": [
{
"hooks": [
{
"type": "command",
"command": "exit 1"
}
]
}
]
}
}
Start claude with claude 'test', and notice how there is no output from the hook.
Claude Model
None
Is this a regression?
Yes, this worked in a previous version
Last Working Version
2.0.76
Claude Code Version
2.1.3
Platform
Anthropic API
Operating System
macOS
Terminal/Shell
Terminal.app (macOS)
Additional Information
My tool, workmux, relied on this behavior to detect new started agents from this hook firing, and calling workmux set-window-status working. https://github.com/raine/workmux/blob/main/.claude-plugin/plugin.json#L12-L21
Would appreciate if it's fixed 🙏
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗