Worktree sessions are transient and cannot be resumed
Problem
When using the Agent tool with isolation: "worktree" or EnterWorktree, the resulting session is a subagent session — it's transient and cannot be resumed via claude --resume.
This is a problem for workflows where users work on multiple tickets in parallel using worktrees and want to return to a specific ticket's session later.
Current Behavior
- Start a Claude session
- Use
EnterWorktreeor Agent tool withisolation: "worktree"to create a worktree session - Do work in the worktree session
- Exit the session
- Try
claude --resume <session-id>→ "No conversation found with session ID" - The session does not appear in the interactive
claude --resumepicker either
The session .jsonl file exists on disk under ~/.claude/projects/ but is not registered as a resumable session.
Expected Behavior
Worktree sessions should be resumable just like regular sessions. They should:
- Appear in the
claude --resumeinteractive picker - Be resumable by session ID
- Support renaming via
Ctrl+Rin the picker - Be searchable by name
Use Case
As an engineer working on ~10 Jira tickets daily:
- I create worktrees per ticket for parallel isolation
- I name sessions with ticket ID prefixes (e.g., "CA-198: internal user SSO")
- I need to return to a ticket's session later for follow-up work
- Worktrees give great branch/file isolation, but the transient session defeats the purpose
Current Workaround
Manually create git worktrees and start Claude directly in the worktree directory as a separate top-level session:
git worktree add .claude/worktrees/CA-198 -b CA-198/feature-name
cd .claude/worktrees/CA-198
claude --name "CA-198: description"
This creates a resumable session, but loses the convenience of creating worktrees from within Claude.
Environment
- Claude Code CLI v2.1.90
- macOS Darwin 24.2.0
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗