Skip to content

Cursor를 서브에이전트 수를 보고하지 않는 agent로 선언 - #921

Merged
yansfil merged 2 commits into
mainfrom
fix/cursor-subagent-count-911
Oct 10, 2026
Merged

yansfil merged 2 commits into
mainfrom
fix/cursor-subagent-count-911

Conversation

@yansfil

@yansfil yansfil commented Oct 10, 2026

Copy link
Copy Markdown
Contributor

Closes #911

Summary

Cursor pane의 서브에이전트 수가 Task 서브에이전트를 돌려도 늘 0이었습니다.
Cursor CLI 2026.10.01-e373342는 subagentStart/subagentStop hook을 agent 서버가 요청할 때만 실행하고, Task 서브에이전트에서는 한 번도 요청하지 않았습니다.
Cursor의 로컬 세션 기록에서 수를 읽을 수 있는지 확인했고, 믿을 만하지 않아 Cursor를 서브에이전트 수를 보고하지 않는 agent로 선언합니다(subagent_counts: None).
그래서 hook은 Cursor에 대해 count를 보고하지 않고, Basic 팝오버는 서브에이전트를 – Not available로 보여 주며, pane의 children 표시는 0 대신 "알 수 없음"(Pi와 같은 uninstrumented, reason unknown)입니다.

Review

  • 판단해 주세요: 세션 기록에서 읽는 대신 선언을 고른 근거입니다. 이 Mac의 ~/.cursor/chats를 읽어 보니 서브에이전트는 부모와 같은 폴더에 자기 store를 가지며 subagentInfo(parentAgentId, toolCallId, typeName)가 있고, 부모 graph에도 Task 호출과 그 tool result가 있습니다. 끝난 서브에이전트는 셀 수 있지만 store 어디에도 "아직 도는 중"을 말하는 표시가 없고, 부모의 Task 호출이 서브에이전트 실행 중에 이미 기록되는지는 실행 중 상태를 볼 수 없어 확인하지 못했습니다. working을 추정해 보이는 것은 0과 같은 종류의 거짓이라(design principle 10) 선언을 골랐고, 읽는 방식은 agent-hooks.md에 근거와 함께 남깁니다.
  • 판단해 주세요: Cursor pane은 count 방언이 없어 children 표시가 uninstrumented(unknown)로 바뀝니다. Pi와 같은 경로이고 "서브에이전트를 알 수 없다"는 사실에 맞습니다.
  • 조심해서 볼 파일: hide-agent-adapter/src/declarations.rs - 선언 한 줄이 설정 기능 목록, 사이드바 projection, hook 보고를 모두 정합니다. hide-agent-hooks/src/bin/hide-agent-hooks.rs의 count_basic은 선언이 없으면 아무것도 보고하지 않습니다.
  • 설치되는 Cursor hook 항목(subagentStart, subagentStop, stop)은 그대로 둡니다. 이미 설치된 hooks.json의 항목을 걷어내려면 별도 retirement 단계가 필요해서 후속으로 남깁니다(subagentStart는 계속 allow로 답합니다).

Evidence

  • 확인한 것: 수정 전 코드에서 cursor_answers_allow_to_each_subagent_start_and_tells_herdr_no_count가 Herdr에 [(1,0),(2,0),(1,1),(0,1)]을 보고해 실패했고, 수정 뒤 통과합니다(hide-agent-hooks/tests/it/grok_cursor_hooks.rs).
  • 확인한 것: 어댑터 계약(support.json에서 Cursor의 subagents 제거), 어댑터 계약 테스트, verify-cargo.sh lint와 test, verify-web.sh, 격리 fixture에서 web/e2e/grok-cursor-hooks.spec.ts 5개 통과(Cursor pane의 count가 null).
  • 확인하지 못한 것: 실제 Cursor pane에서 Settings 팝오버와 children 표시를 화면으로 보지는 않았습니다. 실행 중인 서브에이전트가 세션 기록에 남는 모습도 보지 못했습니다(위 판단 근거).
  • 로컬 전체 test 중 hide-host git 테스트가 한 번 실패했다가 같은 커밋에서 다섯 번 통과했습니다. quarantine 이슈 #920에 남겼고 이 변경과 무관합니다.

Cursor CLI runs subagentStart and subagentStop only when its agent server asks
for them, and a Task subagent run never produced one, so the pane's count stayed
at zero. Its chat store keeps each subagent as a store of its own but nothing in
it says a subagent is still running, so Cursor's adapter now declares no count,
its hook reports none, and the Basic popover lists subagents as not available
instead of showing a zero.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Cursor 서브에이전트 수가 0으로 남음: Cursor CLI가 subagentStart/subagentStop hook을 실행하지 않음

1 participant