Skip to content
Source
Sign inSign up
pingdotgg/t3code

[Bug]: The turn after a steered queued message takes a full workspace snapshot before its prompt #43743

ClosedMauriceCRRR(GitHub profile, opens in a new tab) opened this issue 0 comments

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 thread, send a message. While that turn is running, send a second message. It is queued, then steered into the running turn.
  2. Wait for the turn to end.
  3. Send another message.

Expected behavior

The turn in step 3 finds the previous turn's checkpoint as its baseline and its prompt goes to the provider at once.

Actual behavior

The turn in step 3 takes a full snapshot of the workspace before its prompt is sent.

The queued message gets its own run ordinal. When it is steered into the running turn, that run is cancelled and never writes a checkpoint. The next turn's baseline looks for the checkpoint of the ordinal before it (ordinalWithinScope: Math.max(0, input.run.ordinal - 1) in RunExecutionService.ts), finds none, and snapshots the workspace while the prompt waits. If the snapshot runs out of BASELINE_CAPTURE_BUDGET (5 seconds), the turn starts without a baseline and its changed files and diff are empty. During the wait the working row says "Starting Claude".

Impact

Every message that follows a steered message waits for a full snapshot. In a workspace where a snapshot is slow that is 5 seconds each time, and the turn loses its diff.

Version or commit

0.1.12. The same code is on main at 6bec332fca.

Environment

macOS 27.2, Apple silicon, desktop app 0.1.12, Claude.

Logs or stack traces

From the server trace of one install, within an hour, twice: a run ran, the next message was steered into it, and the run after that took a full snapshot. A baseline that finds its checkpoint takes about 20 ms there; these two took 5,017 and 5,035 ms (the snapshot in that workspace was slow for a separate reason, fixed separately).

  1. tanstack-source added labelsbug

  2. juliusmarminge closed this

Sign in to join this conversation.