Skip to content

fix(sidebar): show Cursor agent rows for native cursor agent titles - #10391

Closed
innocarpe wants to merge 1 commit into
stablyai:mainfrom
innocarpe:fix/cursor-sidebar-title-derived-row
Closed

innocarpe wants to merge 1 commit into
stablyai:mainfrom
innocarpe:fix/cursor-sidebar-title-derived-row

Conversation

@innocarpe

@innocarpe innocarpe commented Jul 24, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • Fixes [Bug]: Cursor Agent session are not shown in the left sidebar #10258: Cursor sessions launched from + appear in the left worktree agent list even when the terminal title is the constant native "cursor agent" string and hooks have not (yet) painted a synthetic status title.
  • Root cause: detectAgentStatusFromTitle("cursor agent") intentionally returns null so re-emissions do not stomp hook-synthesized state. Title-derived sidebar rows required a non-null activity status, so Cursor never got a row from the title path (Codex usually has spinner/working titles).
  • Fix: In title-derived row building, treat Cursor identity titles (isCursorAgentTitle) as idle when activity classification is null. Identity still comes from the existing Cursor label map.

Test plan

  • pnpm exec vitest run --config config/vitest.config.ts src/renderer/src/components/sidebar/worktree-title-derived-agent-rows.test.ts src/renderer/src/components/sidebar/useWorktreeAgentRows.test.ts (41 passed)
  • Launch Cursor from + on Windows → row appears under the worktree with Idle/Running as titles update

ELI5

Cursor agent sessions from + never appeared in the sidebar agent list when the terminal title was the plain cursor agent string. Those sessions now show up as agent rows even before hooks paint a richer title.

@coderabbitai

coderabbitai Bot commented Jul 24, 2026 •

Copy link
Copy Markdown
Contributor

Review Change Stack

📝 Walkthrough

Walkthrough

Cursor title recognition was added to sidebar agent-row derivation. When title activity classification provides no status, recognized Cursor titles now receive an idle status instead of being omitted. Tests cover native "cursor agent" titles launched with Cursor and synthetic "cursor ready" titles without a live hook entry, asserting the resulting Cursor row state and message fields.

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Description check ⚠️ Warning The description has Summary and Testing, but it is missing required AI Review, Security Audit, Notes, and screenshot sections. Add the missing template sections, including Screenshots or No visual change, AI Review Report, Security Audit, and Notes with the required cross-platform review.
✅ Passed checks (4 passed)
Check name Status Explanation
Linked Issues check ✅ Passed The code change addresses #10258 by making Cursor identity titles produce idle sidebar rows when title activity detection is null.
Out of Scope Changes check ✅ Passed The diff stays focused on sidebar agent-row logic and matching tests, with no unrelated or extraneous changes.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Title check ✅ Passed The title clearly and concisely describes the main change: showing Cursor agent rows for native cursor agent titles.

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@nwparker nwparker added the bug Something isn't working label Jul 27, 2026
Cursor's constant native title intentionally yields null activity status so
it cannot stomp hook-synthesized state. Title-derived sidebar rows required
a status, so Cursor sessions never appeared without hooks. Treat Cursor
identity titles as idle when status is null so the row is still built.
@OrcaWin
OrcaWin force-pushed the fix/cursor-sidebar-title-derived-row branch 2 times, most recently from ca38c31 to c4fb9a1 Compare July 28, 2026 03:41
@innocarpe

Copy link
Copy Markdown
Contributor Author

Status ping (merge-oriented): small 2-file sidebar fix for native "cursor agent" titles, with regression tests and no open review threads. Happy to address anything blocking a maintainer pass.

@innocarpe

Copy link
Copy Markdown
Contributor Author

Closing because #10258 was marked completed.

The Cursor sidebar row is no longer an open product gap on main. Keeping this native-title branch open would duplicate a completed issue.

@innocarpe innocarpe closed this Aug 20, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: Cursor Agent session are not shown in the left sidebar

3 participants