Sessions interrupted mid-turn become unresumable despite intact data

Resolved 💬 3 comments Opened Feb 7, 2026 by JayDoubleu Closed Feb 7, 2026

Bug Description

When a session is interrupted mid-turn (e.g. terminal closed, Ctrl+C during tool execution), the session disappears from the /resume list and cannot be resumed, even though the session JSONL and history.jsonl entries are fully intact.

Steps to Reproduce

  1. Start a Claude Code session and have a multi-turn conversation
  2. Issue a prompt that triggers a tool call (e.g. an Edit)
  3. While the tool is executing (progress spinner visible), kill the terminal or Ctrl+C
  4. Reopen Claude Code in the same project directory
  5. Run /resume — the interrupted session does not appear

Expected Behavior

The interrupted session should still appear in /resume. Ideally it would either:

  • Be resumable from the last completed turn (before the interrupted one), or
  • Appear in the list with an indicator that it was interrupted, allowing the user to resume from the last clean state

Actual Behavior

The session is silently dropped from the /resume list. The session JSONL file and history.jsonl entries remain on disk but are inaccessible through the CLI.

Analysis

Comparing an interrupted session with a cleanly-stopped session:

  • Clean session ends with: assistantprogresssystem/stop_hook_summarysystem/turn_duration
  • Interrupted session ends with: assistant (tool_use) → progress — no stop_hook_summary or turn_duration for the final turn

The interrupted session had 8 prior turns that all completed cleanly (each with stop_hook_summary), but the final turn was killed mid-execution. It appears the /resume logic filters out sessions whose last turn didn't complete cleanly, rather than falling back to the last completed turn.

Suggested Fix

When building the /resume list, if a session's final entry is an incomplete turn (no stop_hook_summary), consider:

  1. Still showing it in /resume and resuming from the last cleanly-completed turn
  2. Showing it with an "[interrupted]" label so the user knows the state
  3. At minimum, allowing --resume <session-id> to force-resume even if the session is in an unclean state

Environment

  • Claude Code version: 2.1.37
  • OS: Fedora Silverblue (Linux 6.18.7)
  • Shell: zsh (inside Fedora Toolbox container)

View original on GitHub ↗

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