Skip to content

/reload-plugins does not reload hook scripts — stale hooks persist until session restart #55008

@wphillipmoore

Description

@wphillipmoore

Bug

/reload-plugins does not reload plugin hook scripts into the running session. After updating a plugin that changes a hook, the old hook code continues to execute until the Claude Code process is killed and restarted.

Steps to reproduce

  1. Install a plugin with a PreToolUse hook (e.g., one that denies certain shell commands).
  2. Publish a new plugin version that changes the hook logic (e.g., removes an entry from a deny list).
  3. Run /plugin marketplace update <name> — succeeds, new version appears on disk.
  4. Run /reload-plugins — reports success with a count of loaded items.
  5. Trigger the hook — old behavior persists. The denied command is still denied despite the fix being on disk.

Evidence

Plugin version 1.4.11 had uv in a HOST_TOOLS deny list. Version 1.4.12 removed it. After update + reload:

  • /Users/.../.claude/plugins/cache/.../1.4.12/hooks/scripts/lib/host-container-tools.sh — correct (no uv)
  • Running session still blocks uv with the 1.4.11 error message

The only workaround is to kill and restart the Claude Code session.

Impact

Hooks are the primary mechanism for enforcing agent behavior constraints (blocking dangerous commands, enforcing workflow rules, etc.). When a hook has a bug that incorrectly blocks valid commands, the inability to hot-reload the fix means:

  • Every running session must be killed and restarted
  • There is no way to verify which hook version is loaded without filesystem inspection
  • /reload-plugins gives false confidence — it reports success but hooks remain stale

Expected behavior

/reload-plugins should reload ALL plugin components: skills, hooks, settings, and any other plugin-provided artifacts. If it cannot reload certain components, it should clearly state what was and was not reloaded.

Environment

  • Claude Code CLI (macOS, Darwin 25.3.0)
  • Claude Opus 4.6

Metadata

Metadata

Assignees

No one assigned

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions