Repository navigation
Description
Before submitting
- I searched existing issues and did not find a duplicate.
- I included enough detail to reproduce or investigate the problem.
Area
apps/web
Steps to reproduce
- Open a valid Git repository containing a large number of untracked, non-ignored files (in my case, ~489,890 untracked files totaling ~240 GB of local data/cache files).
- Open the repository in T3 Code v0.1.11 using Current checkout (non-worktree).
- Start a Claude Code thread (
claudeAgent). - Send two consecutive prompts and let both runs complete (
status: "completed"). - During post-turn checkpoint capture for Run 1,
git add -A -- .exceeds the 30-second VCS timeout (VcsProcessTimeoutError), so Run 1's checkpoint is stored withstatus: "error". - Hover over the second user message (Run 2) and inspect the message action bar.
- Observe that Edit from here is completely hidden, leaving only Copy and Copy link.
Additional verification
git rev-parse --is-inside-work-treereturnstrue(branchmain).- Both Claude runs completed normally (
status: "completed"). - No
refs/t3/orchestration-v2/checkpoints/*refs exist in.git/refs/(and checkpoint file lists are[]). - The first user message may still show Edit from here because baseline 0 falls back to
status: "missing"(viamaterializeBaselineCheckpoint), whereas Run 1's failed post-turn capture producesstatus: "error", hiding the button on Run 2 and all subsequent messages. - Distinct from non-Git workspace reports and from [Bug]: "Edit from here" is missing on sent messages, so threads can't be rolled back #36563 (where
providerSessionIdis absent on idle/restarted sessions): here the Git repo is valid and the provider session is active, but a checkpoint capture timeout turns checkpoint status into"error".
Expected behavior
The Edit from here action should remain available for conversation-only rewind when the provider supports rollback and a valid conversation rewind boundary can be resolved, even if Git checkpoint capture fails.
Specifically:
- Allow Revert and keep changes when the conversation can be safely rolled back.
- Disable Revert files too when no valid filesystem checkpoint exists.
- Display a warning explaining that Git checkpoint capture failed and filesystem restoration is unavailable.
- Do not make conversation-only rewind depend on successful Git snapshot creation.
- Preserve the existing safety checks for identifying valid conversation rollback targets.
Since this thread uses Current checkout, filesystem restoration is not needed for the requested operation.
A Git snapshot failure should not automatically disable an otherwise valid conversation-only rewind.
Actual behavior
The Edit from here action is completely hidden on Run 2 (and any turn following a failed checkpoint capture), even when the user only wants a conversation-only rewind (and even in Current checkout mode where file restore is not offered anyway).
Root cause verified in v0.1.11 (and still present on main):
apps/server/src/vcs/GitVcsDriver.ts(captureCheckpoint) stages the workspace viagit add -A -- .in a temporary index.apps/server/src/vcs/VcsProcess.tsenforcesDEFAULT_TIMEOUT_MS = 30_000(5sBASELINE_CAPTURE_BUDGETfor pre-turn baselines inCheckpointService.ts). In workspaces with huge untracked directories (related to [Bug]: Checkpoint capture hits the 30 s git timeout in large workspaces and never converges; every killed attempt leaves a tmp_objdir-bulk-fsync-* directory behind #26227), this times out withVcsProcessTimeoutError.apps/server/src/orchestration-v2/CheckpointService.ts(capture) catches the timeout and records the run's checkpoint withstatus: "error"andfiles: [].- Client gate:
apps/web/src/session-logic.ts(isRewindableCheckpoint) only accepts"ready"or"missing"and rejects"error", soderiveRevertTurnCountByUserMessageIdreturnsundefinedfor the following user message andapps/web/src/components/chat/TimelineUserMessageRow.tsxomits the Edit from here button. - Server gate:
apps/server/src/orchestration-v2/CheckpointRollbackService.ts(execute) similarly rejectscheckpoint.status === "error"withrollback-target-invalideven whenrestoreFiles === false:checkpoint.status !== "ready" && !(checkpoint.status === "missing" && !restoreFiles)
Even though both runs completed, ClaudeAdapterV2.rollbackThread supports native conversation rollback, and conversation-only rewind (restoreFiles: false) does not need a Git snapshot, status: "error" blocks rollback on both client and server.
Suggested fix: Treat status: "error" the same as status: "missing" for conversation-only rewind (restoreFiles === false) in both isRewindableCheckpoint (session-logic.ts) and CheckpointRollbackService.ts, while keeping filesystem restore (restoreFiles: true) restricted to status: "ready".
Impact
Major degradation or frequent failure
Version or commit
v0.1.11 (Orchestrator V2); also verified on main
Environment
macOS 26.5.1 (Apple Silicon / ARM64), T3 Code Desktop v0.1.11 (Orchestrator V2), Claude Code (claudeAgent), local Git repo (Current checkout, main)
Logs or stack traces
# Local diagnostic summary (not a verbatim T3 server log)
$ git rev-parse --is-inside-work-tree
true
$ git ls-files --others --exclude-standard | wc -l
489890
$ git for-each-ref refs/t3/
(empty - 0 checkpoint refs created)
# Isolated temporary-index simulation of GitVcsDriver.captureCheckpoint:
$ GIT_INDEX_FILE=/tmp/test/index GIT_OBJECT_DIRECTORY=/tmp/test/obj git add -A -- .
TIMED OUT (> 30s)
# Thread state observed via T3 orchestration:
# - Run 1: status=completed, checkpoint files=[]
# - Run 2: status=completed, checkpoint files=[]
# - Client hides "Edit from here" on Run 2 (isRewindableCheckpoint rejects status="error")Screenshots, recordings, or supporting files
No response
Workaround
Adding the large untracked data/cache directories to .gitignore (placed after any ! un-ignore rules) reduced untracked files from ~489,890 (~240 GB) to ~1,850 (~365 MB) and brought isolated git add -A -- . time down to 1.4s.
- New turns and new threads after this change capture checkpoints normally and restore the Edit from here button.
- Previously completed turns whose checkpoints were already persisted as
status: "error"remain non-rewindable in existing threads (workaround for those turns is pressingUp Arrowin the empty composer to recall the prompt, or forking into a new thread).
Activity