Prompt-based SubagentStop hooks send feedback but don't prevent termination

Resolved 💬 5 comments Opened Jan 23, 2026 by ddehart Closed Feb 27, 2026

Summary

Prompt-based SubagentStop hooks correctly evaluate and send feedback to the subagent, but do not actually prevent the subagent from terminating. The subagent receives the feedback as a user message but never gets another turn to respond.

Expected Behavior

According to the hooks documentation:

Stop/SubagentStop Decision Control * "block" prevents Claude from stopping. You must populate reason for Claude to know how to proceed.

When a prompt-based SubagentStop hook returns {"ok": false, "reason": "..."}, the subagent should continue working with the provided feedback.

Actual Behavior

  1. Subagent completes its response
  2. SubagentStop hook fires correctly
  3. Haiku evaluates and returns {"ok": false, "reason": "..."}
  4. Feedback is sent to the subagent as a user message with isMeta: true
  5. Subagent session terminates anyway - no additional turn is given

Reproduction Steps

  1. Add a SubagentStop hook in .claude/settings.json:
{
  "hooks": {
    "SubagentStop": [
      {
        "hooks": [
          {
            "type": "prompt",
            "prompt": "Check if output contains 'REQUIRED'. If yes: {\"ok\": true}. If no: {\"ok\": false, \"reason\": \"Missing. Add it now.\"}",
            "timeout": 30
          }
        ]
      }
    ]
  }
}
  1. Invoke any subagent via Task tool
  2. Observe: hook fires, feedback sent, but subagent terminates without continuing

Evidence from Transcript

{"type":"progress","data":{"type":"hook_progress","hookEvent":"SubagentStop",...}}
{"type":"user","message":{"content":"Stop hook feedback: Prompt hook condition was not met..."},"isMeta":true}
// Transcript ends - no subsequent assistant turn

Configurations Tested

  • Hook in agent frontmatter (hooks: Stop:) - same behavior
  • Hook in agent frontmatter (hooks: SubagentStop:) - same behavior
  • Hook in .claude/settings.json with/without matcher - same behavior

Environment

  • Claude Code version: 2.1.17
  • Platform: macOS

Related Issues

  • #5812 mentions SubagentStop feedback isolation
  • #10412 discusses Stop hooks failing via plugins

View original on GitHub ↗

This issue has 5 comments on GitHub. Read the full discussion on GitHub ↗