[BUG] Ctrl+B backgrounding a Bash command makes the session non-resumable in place

Status Open
Reported on v2.1.246
Maintainer reply None cached
Activity 1 comment · opened Aug 26, 2026

Preflight

  • [x] I have searched existing issues and this hasn't been reported yet
  • [x] This is a single bug report
  • [x] I am using the latest version of Claude Code (2.1.246, matches npm)

What's Wrong?

Backgrounding a Bash command with <kbd>Ctrl</kbd>+<kbd>B</kbd> leaves the session unable to resume in place. After exiting, claude --resume <session-id> prints Failed to resume the conversation, exits with code 1, and suggests claude --resume <session-id> --fork-session. Forking works, so the conversation isn't lost — but in-place resume never succeeds again for that session.

It reproduced on every attempt, minting a new forked session each time (four transcripts in four minutes).

What Should Happen?

The session should resume with the background task simply dropped. The sessions doc says, under What a resumed session restores:

Scheduled tasks: tasks that haven't expired are restored. Background Bash and monitor tasks aren't.

That reads as graceful degradation — the task isn't restored, but the session still is. Failing the entire resume contradicts the documented behavior.

Error Messages/Logs

Failed to resume the conversation

followed by exit code 1 and the suggested --fork-session retry command.

Steps to Reproduce

  1. Start an interactive session.
  2. Run a long-running command and press <kbd>Ctrl</kbd>+<kbd>B</kbd> to background it (a test run, in my case).
  3. Exit the session.
  4. claude --resume <session-id>

Ruled out before reporting

  • Transcript corruption — every line of the affected transcripts parses as valid JSON (532 and 2043 lines).
  • Missing session files — the session's side directory and custom-title.json are both present.
  • Nothing was deleted or moved from the working directory, so the doc's "fix the cause and resume in place" advice has nothing to act on.

Impact

<kbd>Ctrl</kbd>+<kbd>B</kbd> is the intended way to background long-running work, so this silently trades away resumability. Each fork mints a new session ID, and forking into a separate process starts without "allow for this session" permission grants, so they all have to be re-approved.

Environment

  • Claude Code 2.1.246
  • macOS (Darwin 25.5.0)
  • Model: Opus
  • Regression: unknown — not tested against an earlier version

View original on GitHub ↗

This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗