/resume hides sessions that used Agent Teams (teamName filter)

Resolved 💬 2 comments Opened Feb 17, 2026 by Grinsven Closed Mar 18, 2026

Bug Description

Sessions where the user spawned Agent Teams are completely hidden from the /resume session picker. The session files exist on disk and work fine with --resume <session-id>, but they never appear in the interactive picker.

Root Cause

In the progressive enrichment function IOz() (minified name), there's a filter that returns null for any session with a teamName:

if (Y.isSidechain || Y.teamName) return null;

This correctly filters out teammate sessions (spawned subagents), but it also filters out the team leader session — which is the user's actual interactive session where they typed prompts and managed the team.

Steps to Reproduce

  1. Start a new Claude Code session
  2. Use Agent Teams (e.g., spawn teammates via the Task tool with team_name)
  3. End the session
  4. Run /resume or claude --resume
  5. The session is missing from the picker

Expected Behavior

The team leader session (the one the user directly interacted with) should appear in the resume picker. Only teammate/subagent sessions should be hidden.

Workaround

Resume by session ID directly:

claude --resume <session-id>

Session IDs can be found by listing JSONL files:

ls -lt ~/.claude/projects/<project-dir>/*.jsonl | head -20

Environment

  • Claude Code: 2.1.44 (bug present since at least 2.1.30 when stat-based loading replaced sessions-index.json)
  • OS: macOS (Darwin 25.2.0)
  • Runtime: Bun 1.3.9

Additional Context

The teamName property is written to every message in the session JSONL once a team is created. The fix should distinguish between the team leader session and teammate sessions — e.g., by checking if the session also has agentSetting or was spawned via a teammate-message, rather than blanket-filtering on teamName presence.

View original on GitHub ↗

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