fix(sessions): fold Cursor Tasks under Agent Sub-Sessions like Codex#262
Open
zephyr110 wants to merge 3 commits into
Open
fix(sessions): fold Cursor Tasks under Agent Sub-Sessions like Codex#262zephyr110 wants to merge 3 commits into
zephyr110 wants to merge 3 commits into
Conversation
Cursor IDE Tasks use a child session_id while transcript_path still points at the parent chat, which created duplicate cards. Honor separate/merge/hide, keep closed subagent ids across Stop (and idle-orphan merge drops), deny late Permission/AskUserQuestion/Question for closed agent ids, drop idle orphans without resuscitating via a shared IDE pid, fill missing parent identity from merge-first Task hooks, reopen Cursor Tasks via beforeSubmitPrompt after Stop, keep the parent active while folded Tasks run, and avoid dual-tailing the parent transcript when splitting to separate cards.
Keep folded deny/answer from idling the parent, drop idle orphans without overwriting live Tasks, and only self-tombstone foldable separate Task cards.
Async XCTest teardown released AppState off MainActor and trapped in assumeIsolated; use weak-boxed FSEvents teardown so discovery stays safe.
nguyenvanduocit
pushed a commit
to nguyenvanduocit/CodeIsland
that referenced
this pull request
Jul 15, 2026
…atch added to T-073 No new commits to wxtsky/CodeIsland since v1.0.30 (Jul 10). One new open PR wxtsky#262 (Jul 14): fix(appstate) ProjectsWatcherBox for FSEvents teardown safety — noted as prerequisite for T-073 implementation. vibe-island unchanged. No new GitHub issues created. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01X1rG9TcKyFd2mpEVXb9n6k
nguyenvanduocit
pushed a commit
to nguyenvanduocit/CodeIsland
that referenced
this pull request
Jul 16, 2026
Upstream quiet since v1.0.30 (Jul 10). One new watch item: - T-076: panel intermittently shifts from notch to upper-left corner on macOS 27.0 beta (issue wxtsky#263, M5 Pro, no upstream fix yet) Skip: PR wxtsky#264 (OMP), PR wxtsky#262 (Cursor Tasks), issue wxtsky#265 (Cursor) — all non-Claude CLIs or Cursor-specific. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01P5RZPP2LLwKBjbXuqKxDjf
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
separate/merge/hide) for Cursorcursor/cursor-clihooks whosetranscript_pathis under…/agent-transcripts/<parentId>/…whilesession_idis a child. Merge rewrites to the parent +agent_id; hide drops the child; separate (default) keeps a separate card — no forced merge.UserPromptSubmit/beforeSubmitPrompt. When splitting to separate, do not tail the parent transcript twice.cliPid. PersistclosedSubagentIds. Settings copy mentions Cursor Task/subagent.AppStatedeinitoff the main actor (async XCTest / ARC). FSEvents callbacks hold a weak-boxed watcher so queued main-queue deliveries stay safe; avoidsMainActor.assumeIsolatedtraps.CursorSessionFoldingTests,AppStateCursorSubsessionTests,SessionPersistenceTests,AppStateDeinitTests.中文说明
cursor/cursor-cli)在「子 session_id + transcript 仍指向父对话」时,走同一套 Agent 子会话设置。合并 → 父 session +agent_id;隐藏 → 丢弃;默认独立显示,不强制合并。cliPid;持久化closedSubagentIds;设置文案补充 Cursor Task/subagent。deinit(异步 XCTest / ARC)。FSEvents 经弱引用 box 回调,避免MainActor.assumeIsolated崩溃。AppStateDeinitTests。Test Plan
DEVELOPER_DIR=/Applications/Xcode.app/Contents/Developer—CursorSessionFoldingTests(24),AppStateCursorSubsessionTests(26),SessionPersistenceTests(6),AppStateDeinitTests(1) — all passedL10n+SettingsDefaults.pluginSessionMode == "separate")AfterAgentResponse/Stop(unit coverage: fold + parent keeps active).runningwith toolAgent, not.idle(unit coverage:testMergedPermissionMarksSubagentWaitingApproval)AppStateno longer SIGTRAP on teardown (AppStateDeinitTestspassed)