{"version":"2.1.238","anchor":"refused-subagent-launches-are-recorded-with-a-reason","canonical_anchor":"refused-subagent-launches-are-recorded-with-a-reason","heading":"Refused subagent launches are recorded with a reason","tier":"internal","area":"Subagents","scope":null,"heads_up":null,"url":"https:\/\/changelogs.core-directive.com\/v\/2.1.238\/e\/refused-subagent-launches-are-recorded-with-a-reason","release_url":"https:\/\/changelogs.core-directive.com\/v\/2.1.238","markdown":"### Refused subagent launches are recorded with a reason\n\nA turned-down subagent launch now records whether it hit the nesting cap, the concurrency cap or a budget.\n\n**What**\n\nWhen a Task launch is turned down, the session now records why alongside the existing telemetry, giving three named reasons: `depth_limit` for the nesting cap, `concurrency_limit` for too many at once, and `budget` for an exhausted allowance.\n\n**Details**\n\n- The depth cap still throws the same error naming `CLAUDE_CODE_MAX_SUBAGENT_SPAWN_DEPTH`; the refusal is recorded just before it throws.\n- Task rows gained a `spawnedSubagent` field, and `spawnDepth` is now written only when it applies.\n- The concurrency check reads the session's effort setting through a new accessor rather than off the app state directly.\n\n**Evidence**\n\n`recordRefused(\"depth_limit\")`, `recordRefused(\"concurrency_limit\")`\n\n- Area: Subagents\n- Tier: Under the hood\n- Useful: 2\/5\n- Signal: 3\/5"}