Hooks issues on Linux
Issues the maintainers labelled both platform:linux and area:hooks.
102 issues · 17 open · 85 resolved (83%) · first seen Aug 5, 2025
Is this getting better or worse?
This class of problem is converging. 34 new reports in the last 90 days vs 60 in the 90 before — -43%. The open backlog peaked at 31 in 2026-04 and sits at 17 today.
Derived by counting each matching issue from its creation date until it closed. First-party
computation over the anthropics/claude-code tracker — the trend is not published
anywhere upstream.
Which builds report this
68 of these reports name the Claude Code build they were running, spanning 50 releases. Heaviest reporters:
- Claude Code v2.1.206
- Claude Code v2.1.111
- Claude Code v2.1.119
- Claude Code v2.1.74
- Claude Code v2.1.234
- Claude Code v2.1.233
- Claude Code v2.1.123
- Claude Code v2.1.158
Report volume, not a defect count: an issue can mention a build without that build having caused the failure. Versions come from the version string in the bug-report template, matched against real published tags.
Do these get fixed?
Median time to close is 32 days across 85 closures. Of the 85 closures with a recorded reason, 28% were closed as completed and 61 as not-planned or duplicate. The most recent completed fix landed in 2026-08.
Workarounds reported by the community
37 of these issues post a workaround someone says worked. The highest-engagement ones:
- PermissionRequest hooks not triggered for subagent permission requests in Agent Teams
- …The current behavior makes these two features incompatible. Workaround Pre-approve common subagent commands in permissions so they don't need to ask: This lets subagents work autonomously but removes the ability to revie…
Found in the description of #23983 · still open - [Critical] Max Plan subscriber: Opus 4.6 instruction-following regression breaks production workflows — 24-hook enforcement system cannot compensate for model-level degradation
- …survive compression with their priority intact. Pattern E: "Workaround Generation" When a hook blocks a forbidden action, the model generates creative alternatives that achieve the same forbidden outcome through a differ…
Found in the description of #34358 · resolved - v2.1.23+ causes 100% CPU hang with multiple parallel instances and hooks
- …- The UI becomes unresponsive - Process must be killed with Workaround Using v2.1.22 resolves the issue completely: With v2.1.22, everything works perfectly - all hooks, all plugins, multiple parallel instances. Potentia…
Found in the description of #22172 · resolved - PreToolUse/PostToolUse hooks do not fire for subagent (Agent tool) tool calls
- …which is the primary recommended workflow for performance. Workaround We query the actual systems of record ( , Jira API) at checkpoint time rather than trusting hook-maintained counters, and reconcile the state file af…
Found in the description of #34692 · resolved - Ralph Loop plugin: stop-hook.sh missing execute permission on Linux
- …marketplace plugin ( ), not just third-party marketplaces. Workaround Expected Fix The plugin should either: 1. Ship files with the execute bit set in the repository ( ) 2. Or have the plugin installer set on hook scrip…
Found in the description of #38686 · resolved
Excerpts are quoted from the linked issue so you can judge relevance before opening it. Threads that only ask for a workaround, or report that there is none, are excluded. These are community suggestions, not official guidance from Anthropic — read the full thread before applying one.
Matching issues 1–100
Ranked by community engagement (reactions weighted over comments).
- [BUG] Notification Hook 10 second delay
- PermissionRequest hooks not triggered for subagent permission requests in Agent Teams
- [Critical] Max Plan subscriber: Opus 4.6 instruction-following regression breaks production workflows — 24-hook enforcement system cannot compensate for model-level degradation
- v2.1.23+ causes 100% CPU hang with multiple parallel instances and hooks
- PreToolUse/PostToolUse hooks do not fire for subagent (Agent tool) tool calls
- [BUG] Worktree cleanup prompt isn't used when custom worktree hooks are enabled
- [BUG] [BUG] SSH-Remote ccd-cli 2.1.128 still exits with code 1 on initialize with hookCallbackIds — regression of #50698
- Ralph Loop plugin: stop-hook.sh missing execute permission on Linux
- CLAUDE_ENV_FILE: session ID mismatch on resume causes env files to be written to wrong directory
- Team-spawned agents: agent frontmatter hooks don't fire, MCP servers not inherited, agent_type missing from hook payloads
- [BUG] PreToolUse hook permissionDecision "allow" does not suppress native permission prompt in interactive mode (v2.1.119)
- [BUG] Project settings.json not found in bare repo + worktree setup
- [BUG] skills and plugins share the same /plugin install surface
- Agent-level hooks defined in .claude/agents/*.md frontmatter don't fire when run from CLI
- [BUG] Remote SSH daemon (ccd-cli/2.1.111) exits with code 1 on initialize when hookCallbackIds are present
- [BUG] Hooks from non-enabled marketplace plugins still fire during SessionStart
- Plugin deployment strips execute bit from hook shell scripts
- Plugin cache strips execute permission from hook scripts
- Worktree creation rewrites shared core.hooksPath, silently disabling repo-managed git hooks for the whole clone
- VS Code extension: Notification hooks don't fire on permission-approval or elicitation dialogs
- [BUG] Stop hook exit code 2 downgraded to non-blocking when stderr contains unrelated 'no such file'
- Extra blank lines rendered around SessionStart hook output and first response
- [BUG] 2.1.190 Linux: active session transcript .jsonl not written until session exit; hooks get empty transcript_path mid-session
- PreToolUse hook `if` filter false-positives on complex Bash commands
- [BUG] SessionStart prompt hooks crash with unhandled exception
- [BUG] PreToolUse hook sometimes causes permission prompt to fail.
- Model reasons past PreToolUse deny based on conversation context (semantic bypass)
- [BUG] Hook runner fails with "Permission denied" when plugin shell scripts lack execute bit
- [BUG] Environment Variables from SessionStart Hooks are not cleared on /clear
- PreToolUse hook permissionDecision 'deny' not enforced for MCP server tool calls
- Hooks fail on non-FHS systems (NixOS): ENOENT posix_spawn '/bin/sh'
- [BUG] `normalizeToolInput` strips `cd <cwd> &&` from Bash commands before PreToolUse hooks can inspect them
- [Feature Request] Add statusline customization setting for managed hook environments
- PreToolUse hook input missing agent_id for tmux/pane-based teammates
- [BUG] transcript_path in stop hook uses cwd hash instead of git-root hash when running in a git worktree
- Plugin update loses executable permission on .sh hook files
- ralph-loop plugin: stop-hook.sh Permission denied — /bin/sh is dash on Ubuntu
- [BUG] Accessing `/hooks` menu in worktree causes project-level hooks to be unloaded
- SessionStart hooks do not fire on /clear (related to #10373)
- [BUG] ResultMessage never emitted in headless SDK mode when Stop hook matches 0 hooks after long-running agent with background subagents
- Stop hook not fired when Claude stalls mid-turn after tool result (silent tool stop)
- [Bug] Remote Control: PreTooluse hook auto-allowed permissions still prompt for confirmation
- PermissionRequest hooks: subagent prompts don't invoke the hook; when it did fire, a returned allow was ignored
- [BUG] Forcefully-injected SessionStart instructions are silently bypassed when the first user turn is conversational
- Hook stdout shown + suppressOutput:true ignored in 2.1.158 (regressed from 2.1.157)
- [BUG/FEATURE] PreToolUse hook resolving path
- [BUG] Claude Desktop SSH Remote: ccd-cli 2.1.128 crashes on initialize when hooks are configured in settings.json
- PermissionRequest hook decision rendered 20+ times in UI for a single tool invocation
- PostToolUse prompt hooks fail on Vertex AI backend with 'output_config: Extra inputs are not permitted'
- PreToolUse hook: `if` filter on handler silently matches nothing
- Python hooks silently fail: stdout not flushed before pipe closes
- Subagents with bypassPermissions ignore PreToolUse hooks — unauthorized commands, wasted tokens
- SessionStart hook output saved to disk at ~10K instead of documented 50K threshold
- Plugin marketplace install strips execute permissions from .sh files
- [BUG] Learning output style plugin lose execute permission on reload
- Hook output display doesn't distinguish between blocking (exit 2) and failure (exit 1)
- hookify plugin: broken Python imports — ModuleNotFoundError on every hook execution
- [BUG] PostToolUse hook stdout JSON output duplicated in terminal and context (re-filing #23381)
- Plugin hooks: shared Python process caches sys.modules across tool calls, causing stale import errors
- [BUG] PostToolUse hook exit-2/stderr warning not delivered to model in VSCode extension
- Hook timeout does not reclaim a hook blocked in a read syscall — SIGTERM ignored, process survives indefinitely
- [BUG] ConfigChange hook emitting blocking decision is not respected by claude code CLI
- Stop hook does not fire reliably in VSCode extension (works via CLI, confirmed via git history)
- Session-env snapshot file breaks when sourced: unquoted LS_COLORS/SSH_CONNECTION/LESSCLOSE spam 'command not found' on every Bash call
- [BUG] AskUserQuestion prompts fire Notification hook as notification_type=permission_prompt instead of a question-specific type
- [BUG] @file reference bypasses PreToolUse hooks (e.g. .env read block)
- [FEATURE] Machine-readable hook I/O schemas shipped with the binary (`claude hooks schema --json`)
- [Feature Request] Add PreVoiceInput hook or voice.enabled-when condition for conditional voice-mode gating
- Feature: Landlock sandbox directives for PreToolUse hooks
- Hook hot-reload silently breaks when settings.json is replaced (atomic save / git checkout / symlinked dotfiles)
- [Bug] UserPromptSubmit hook error: Missing required field "hookEventName" in hookSpecificOutput
- settings.json gets "UserPromptSubmit": null written when a plugin contributes that hook
- [BUG] SessionStart hooks should complete before scheduled_tasks.json is loaded by cron scheduler
- [BUG] PreToolUse/Edit hook not triggered when old_string doesn't match file content
- Plugins should declare and verify system dependencies
- Plugin cache dir deleted mid-session when git commits change HEAD — causes infinite Stop hook loop
- Linux: hook blocked reading stdin (pipe kept open, no EOF) wedges the session for hours; declared hook timeout not enforced (2.1.246)
- [Bug] Interactive auto mode bypasses permissions.ask rules for PreToolUse decisions
- [BUG] tmux/pane-backed teammates have no agent_id/agent_type in hook payloads — indistinguishable from the main agent (re-file of #54785, still present on 2.1.233)
- Plugin hooks never run when the plugin is installed from a directory-source marketplace
- SubagentStop decision:block is silently discarded when the agent has a structured output schema
- SubagentStop: hookSpecificOutput.additionalContext continues the subagent's turn but never reaches the subagent; decision:block delivers but replaces the deliverable
- Transcript writer intermittently drops assistant text blocks ("mute windows"); thinking/tool_use of the same messages persist
- [BUG] SessionEnd hooks never fire for long-lived `remote-control` sessions — lifecycle automation silently dead
- Feature: SessionStart hook should fire on /branch with source:"branch" and branch_name
- UserPromptSubmit hook timeout is hardcoded to 30s (HN4=30000) with no override; context silently dropped on timeout
- [BUG] SessionEnd hook creates infinite recursive loop when spawning a claude CLI subprocess
- [BUG] extensibility.py follows symlinks in project-controlled guidance file, sending local file content to API
- Hook stdout shown + suppressOutput:true ignored in 2.1.158 (regressed from 2.1.157)
- Stop hook does not fire when the CLI is terminated by SIGTERM (e.g. external execution timeout)
- [BUG] /doctor schema validator rejects exec-form (args[]) hooks added in 2.1.139
- --worktree --tmux skips WorktreeCreate/WorktreeRemove hooks
- [FEATURE]: Allow the built-in /goal Stop hook under allowManagedHooksOnly (or add a managed opt-in)
- `hasTrustDialogAccepted: false` coexists with fully-working hooks in 2.1.241 — no reliable programmatic signal for workspace trust
- Read dedup does not account for PostToolUse updatedToolOutput: repeated Reads bypass substituting hooks, and readFileState records disk content the model never received
- [BUG] ~/.claude/settings.local.json is only applied to sessions started in $HOME — permissions and hooks silently inert elsewhere
- Bash tool shell runs with `expand_aliases` enabled — shell aliases can silently rewrite commands after PreToolUse hook approval
- PostToolUse hooks do not fire in daemon/background-job sessions (PreToolUse + SessionStart do) — v2.1.208
- [FEATURE] Render hook system messages with user-facing labels
- Hooks fail open when CWD is invalidated (e.g. worktree deletion)