Skip to content

[BUG] 🚨 --continue and -p are now seriously broken together in 2.1.90 #43013

Closed as not planned

Description

@stbenjam

Preflight Checklist

  • I have searched existing issues and this hasn't been reported yet
  • This is a single bug report (please file separate reports for different bugs)
  • I am using the latest version of Claude Code

What's Wrong?

claude --continue -p "..." no longer works when the originating session was also started with -p.

WORKAROUND: export CLAUDE_CODE_ENTRYPOINT=sdk-cli (Just cli prior to 2.1.108)

Root Cause

This is caused by the 2.1.90 change: "Changed --resume picker to no longer show sessions created by claude -p or SDK invocations".

The flow is:

  1. claude -p "..." creates a session tagged with sessionKind = "print" (or similar)
  2. claude --continue -p "..." scans for the most recent session → the enrichment function filters it out because sessionKind is set → returns null
  3. loadInitialMessages sees null from the --continue block, silently falls through with no error, and starts a brand new empty session

The --continue flag should bypass the sessionKind filter, since its explicit purpose is to continue the most recent session regardless of how it was created.

Additionally, the silent fallthrough is a design issue — if --continue can't find a session, it should error rather than silently starting fresh.

What Should Happen?

--continue -p should continue the most recent session created by any previous invocation, including -p sessions. If no session can be found, it should emit an error rather than silently creating a new session.

Error Messages/Logs

No session to continue.

Steps to Reproduce

cd $(mktemp -d)
claude --max-turns 1 -p "The answer is 42. Reply only with: OK"
claude --continue # note the previous session isn't continued

Important: Must be run from a standalone shell, NOT from within a Claude session - having CLAUDE_CODE_ENTRYPOINT set masks the problem

Claude Model

Opus

Is this a regression?

Yes, this worked in a previous version

Last Working Version

2.1.89

Claude Code Version

v2.1.90, v2.1.91, v2.1.92

Platform

Google Vertex AI

Operating System

macOS

Terminal/Shell

iTerm2

Additional Information

We rely on this functionality to run Claude in CI for multi-stage workflows where each stage uses --continue -p to build on the previous stage's context.

Activity

  1. github-actions commented on Apr 3, 2026

    @github-actions

    Found 1 possible duplicate issue:

    1. --continue on 2.1.90 silently drops conversation context (regression from 2.1.89) #42376

    This issue will be automatically closed as a duplicate in 3 days.

    • If your issue is a duplicate, please close it and 👍 the existing issue instead
    • To prevent auto-closure, add a comment or 👎 this comment

    🤖 Generated with Claude Code

  2. jocel1 commented on Apr 3, 2026

    @jocel1

    It's related to the change from 2.1.90: "Changed --resume picker to no longer show sessions created by claude -p or SDK invocations"

  3. stbenjam commented on Apr 3, 2026

    @stbenjam
    Author

    Maybe similar to #42376? Some bad things happened to resume / continue.

    For me this is a workaround:

    export CLAUDE_CODE_ENTRYPOINT=cli
    
  4. stbenjam commented on Apr 3, 2026

    @stbenjam
    Author

    Actually #42376 is not quite the same, they are not using -p, but I think the causes are related.

  5. 15 remaining items

  6. stbenjam commented on May 24, 2026

    @stbenjam
    Author

    This is still broken in 2.1.150.

    Image
  7. stbenjam commented on Jun 1, 2026

    @stbenjam
    Author

    Still broken in 2.1.159.

  8. stbenjam commented on Jun 17, 2026

    @stbenjam
    Author

    Still a problem in 2.1.179

    stbenjam@fedora:/tmp/tmp.o1TlosHU6j$ claude -p "Hello world"
    
    
    Hello! How can I help you today?
    stbenjam@fedora:/tmp/tmp.o1TlosHU6j$ claude --continue
    No conversation found to continue
    stbenjam@fedora:/tmp/tmp.o1TlosHU6j$ claude --version
    2.1.179 (Claude Code)
    
  9. github-actions commented on Jul 29, 2026

    @github-actions

    Closing for now — inactive for too long. Please open a new issue if this is still relevant.

  10. github-actions commented on Sep 23, 2026

    @github-actions

    This issue has been automatically locked since it was closed and has not had any activity for 7 days. If you're experiencing a similar issue, please file a new issue and reference this one if it's relevant.

  11. locked as resolved and limited conversation to collaborators on Sep 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    api:vertexIssue relates to GCP Vertexarea:clibugSomething isn't workingduplicateThis issue or pull request already existshas reproHas detailed reproduction stepsplatform:macosIssue specifically occurs on macOSregressionstaleIssue is inactive

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions