Where does the bug appear (feature/product)?
Cursor IDE
Describe the Bug
Hooks provide no way to associate a subagent’s conversation with the parent conversation that spawned it.
Two related problems (Cursor IDE 3.7.27, macOS):
1. subagentStart fires under the parent’s conversation, with a self-referencing parent id. The docs imply this hook describes the subagent’s new conversation, but in practice conversation_id == parent_conversation_id — so the field adds no information:
{
"hook_event_name": "subagentStart",
"conversation_id": "955a0282-ab19-40f3-8074-930fe44e6251",
"parent_conversation_id": "955a0282-ab19-40f3-8074-930fe44e6251",
"subagent_id": "tool_f11bf24d-1575-49ed-819d-dc51f100be9",
"tool_call_id": "tool_f11bf24d-1575-49ed-819d-dc51f100be9",
"subagent_type": "shell",
"subagent_model": "...",
"session_id": "955a0282-ab19-40f3-8074-930fe44e6251",
"generation_id": "955a0282-ab19-40f3-8074-930fe44e6251"
}
(subagent_id is just the parent’s Task tool_call_id; session_id and generation_id also just repeat the conversation id. Same for subagentStop.)
2. The subagent’s own hooks carry no linking field at all. The subagent then runs under a fresh conversation_id (here 3209bc72-…), and its preToolUse/postToolUse payloads contain nothing referencing the parent: session_id == conversation_id (its own), generation_id is a fresh UUID, transcript_path is null, and the spawning tool_call_id appears nowhere.
Steps to Reproduce
- Subscribe a hook script to
subagentStart,preToolUse,postToolUsethat dumps stdin to a file. - In a chat, ask the agent to perform a task using a subagent (Task tool).
- Compare the
subagentStartpayload with the subagent’spreToolUsepayloads: there is no shared identifier linking the child conversation to the parent.
Expected Behavior
Either of:
subagentStartincludes the subagent’s (new)conversation_idas a distinct field, or fires under the subagent’s conversation withparent_conversation_idpointing at the actual parent — as the field name suggests; or- hooks fired inside a subagent conversation include
parent_conversation_id(and ideallysubagent_id/subagent_type).
This matters for observability/security tooling built on hooks: without a linkage, one user conversation that uses N subagents appears as N+1 unrelated conversations, and there is no way to reconstruct the session tree. (Claude Code’s hooks handle this by keeping the parent session_id on subagent hooks and adding agent_id/agent_type.)
Operating System
MacOS
Version Information
IDE:
Version: 3.7.27
VS Code Extension API: 1.105.1
Commit: e48ee6102a199492b0c9964699bf011886708ba0
Date: 2026-06-10T01:46:16.942Z
Layout: editor
Build Type: Stable
Release Track: Default
Electron: 39.8.1
Chromium: 142.0.7444.265
Node.js: 22.22.1
V8: 14.2.231.22-electron.0
xterm.js: 6.1.0-beta.256
OS: Darwin arm64 25.5.0
About Cursor CLI
CLI Version 2026.06.11-03-15-00-241fc09
Model Composer 2.5 Fast
Subscription Tier Free
OS darwin (arm64)
Terminal apple-terminal
Shell zsh
Does this stop you from using Cursor
No - Cursor works, but with this issue