Skip to content

[Bug]: Reverting past a Claude compaction breaks the thread: every send fails with "No message found with message.uuid" #17423

Open

Description

@elmarbeckmann

Before submitting

  • I searched existing issues and did not find a duplicate.
  • I included enough detail to reproduce or investigate the problem.

Area

apps/server

Steps to reproduce

  1. In a Claude (claudeAgent) thread, finish a few turns. Call the last completed turn N. Its final assistant message has UUID X.
  2. Send another prompt. During that run, a manual /compact writes a compact_boundary to the session transcript (trigger: "manual", with preservedSegment / preservedMessages). Let the run continue after the compaction.
  3. Revert the thread to the end of turn N, so that the runs after N are rolled_back.
  4. Send any new message.

Expected behavior

The thread resumes from the end of turn N and the new message runs.

Actual behavior

The revert succeeds. After it, every send fails within about 1 s:

Provider error: No message found with message.uuid of: <X>

The thread stays failed, and every later message gives the same error. You cannot recover the thread from the UI.

The cause, from the session transcript (~/.claude/projects/<project>/<session>.jsonl):

  • Line 547: assistant message X (end of turn N). Line 548: its stop_hook_summary.
  • Line 594: the compact_boundary from the rolled-back run (parentUuid: null, logicalParentUuid points to the end of that run).

T3 resumes with resumeSessionAt: X. The CLI loads only the chain after the newest compact_boundary, so X is not in the loaded messages and the resume fails. The rollback leaves the transcript as it is, which makes the resume point unreachable.

Workaround: Truncate the transcript after line 548, which removes the rolled-back runs and the boundary. The thread then resumes normally.

Related but different: #13638. There, the rewind itself fails after a preserved-segment compaction. Here, the rewind succeeds and every later send fails.

Possible fixes

  • Before rollback, check whether a compact_boundary exists after the target message. If one does, fork or truncate the transcript at the target instead of only pinning resumeSessionAt, or block the rollback with the existing "Start a new thread instead" message.
  • When the provider returns "No message found with message.uuid", let the user recover the thread (for example, drop the pinned resume point or fork from durable history), so that the thread does not stay broken.

Impact

Blocks work completely

Version or commit

T3 Code Nightly 0.0.46-nightly.20261009.2861 (macOS)

Activity

  1. juliusmarminge commented on Oct 22, 2026

    @juliusmarminge
    Member

    Reproduced on current main b5a226e49c with the real web dev app on Linux and Claude Sonnet 5.5. Completed two turns, ran manual /compact (with preserved-message metadata), completed another turn, then used Edit from here on the second prompt and Revert and keep changes. The rewind succeeded; three subsequent sends each failed with No message found with message.uuid for the retained first assistant message. The transcript still contains that message before the compaction boundary. Runtime transcript.

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

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions