Worktree sessions are transient and cannot be resumed

Resolved 💬 3 comments Opened Apr 2, 2026 by yogeswaran-ganesan Closed Apr 6, 2026

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

  1. Start a Claude session
  2. Use EnterWorktree or Agent tool with isolation: "worktree" to create a worktree session
  3. Do work in the worktree session
  4. Exit the session
  5. Try claude --resume <session-id>"No conversation found with session ID"
  6. The session does not appear in the interactive claude --resume picker 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 --resume interactive picker
  • Be resumable by session ID
  • Support renaming via Ctrl+R in 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

View original on GitHub ↗

This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗