Bug: /compact + /rename session not resumable by slug/name, only by UUID
Resolved 💬 3 comments Opened Mar 8, 2026 by vimholic Closed Mar 11, 2026
Bug Report
Summary
After running /compact, the new session inherits the same slug as the previous session. When /rename is used to assign a custom title, the session cannot be resumed by slug or custom name — only by UUID. The session picker also hides the post-compact session when a duplicate slug exists.
Steps to Reproduce
- Start a session and run
/compact→ a new session is created (new UUID, same slug inherited from the previous session) - Run
/rename <unique-name>to assign a custom title to the new session - End the session and open a new
claudeinstance - Try to resume via the interactive picker (
/resume) orclaude --resume <name>
Expected Behavior
- The renamed session should appear in the resume picker
claude --resume <slug>andclaude --resume <custom-name>should both work/compact-derived sessions should be distinguishable and resumable independently
Actual Behavior
- The session does not appear in the interactive resume picker
claude --resume <slug>fails (slug is shared with the pre-compact session, picker only shows one entry per slug)claude --resume <custom-name>(the name set via/rename) also fails- Only
claude --resume <UUID>works
Root Cause Analysis
/compactcreates a new session that inherits the same slug as the previous session- The resume picker appears to show only one entry per slug → the post-compact session is hidden behind the pre-compact one
/renamesets acustomTitle, but this title is not indexed or matched in the resume picker or--resumeflag lookup- Even
--resume <slug>fails to reliably target the correct (latest) session when multiple sessions share the same slug
Environment
- Claude Code version:
v2.1.71 - OS: WSL2 (Ubuntu on Windows)
- Shell: bash
Additional Notes
A reasonable fix would involve one or more of:
- Assigning a new, unique slug to sessions created by
/compactinstead of inheriting the parent slug - Making the resume picker show all sessions with the same slug (e.g. with timestamp disambiguation), not just one
- Making
--resumeand the picker search bycustomTitle(set via/rename) in addition to slug and UUID
This makes post-compact sessions effectively unresumable by human-readable name, which undermines the utility of both /compact and /rename.
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗