[Nit]: No "starting agent" state while the provider boots; only "Syncing messages..." shows for ~15s #14244
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#
- Run
t3 serveon a Linux host and connect from the macOS desktop app through the relay. - Start a new Claude thread and send the first message, on a host where the Claude CLI is slow to boot (in my case the host was heavily loaded).
- Watch the composer and timeline while the provider session starts.
Expected behavior#
While the server is starting the provider session and waiting for the first provider event, the UI shows what it is doing (for example "Starting Claude…"), and the "Working for Xs" row appears as soon as the message is sent.
Actual behavior#
For about 15s the composer only shows "Syncing messages...", which describes the client's thread-detail sync state, not the provider. After that, "Working for 16s" appears with the timer already partly elapsed. From the UI you can't tell whether the message was received, whether the connection is broken, or whether the agent is starting up.
Server trace for that turn (thread a81c39ea…, all times UTC):
08:08:44.270 orchestration.command.thread.turn.start 93ms
08:08:44.502 processTurnStartRequested 1879ms
08:08:45.024 ensureSessionForThread 1356ms
08:08:45.886 startSession (claudeAgent) 102ms
08:08:46.415 sendTurn 13900ms <- no user-visible state for this whole span
08:08:47.361 ws.rpc.orchestration.subscribeThread Interrupted (4.1s)
08:08:51.395 ws.rpc.orchestration.subscribeThread Interrupted (31.4s)
08:08:59.736 turn.started (first provider event)
Most of the 13.9s sendTurn is Claude CLI boot. On the same host, claude -p took 14.2s to emit system/init even with --strict-mcp-config. That part is environmental. The UI issue is that nothing tells the user this phase is happening, and the working indicator doesn't appear until it ends.
Impact#
Nit: minor UX polish. Nothing breaks and no data is lost.
Version or commit#
t3 v0.0.42
Environment#
Server: Ubuntu, Linux 7.0.0, headless t3 serve (background service), 8 cores and 6.6 GB RAM, heavily loaded (load avg ~100). Client: macOS desktop app over the t3coderelay relay. Provider: Claude Code 2.1.283.
Workaround#
None. You just have to wait.
juliusmarminge added labelsbug
juliusmarminge added labelsvia-triage
Still present on
mainat 8f75697b9e:isConnectinginChatView.tsxis stilluseState(false)and its setter is never called, so astartingsession isn't shown as working after the draft promotes to the thread route.The triage above named #14000 as the right fix. It was closed for missing live-client verification, and that evidence was posted on the PR about an hour later. It includes before/after screenshots and recordings of a delayed
SessionStarthook, a reload during startup, and a failed startup. @juliusmarminge, could #14000 be reopened for reconsideration? It's a one-file change, and Macroscope approved it.juliusmarminge added labelsneeds more info
juliusmarminge removed labelsneeds more info
Same missing startup state, different host: Windows desktop + Cursor SDK, still on current stable.
Confirmed on T3 Code 0.1.2 (
044f072), desktop app against the local server. Latest nightly0.1.2-nightly.20261022.3541is the same commit, so this is not a behind-stable case. Cursor Agent CLI2026.10.22-27dcf5fis authenticated and healthy (agent about --format json~2.3s when idle). Protocol:cursor-agent-sdk.local. Model: grok-4.6, effort high, Fast off.After a long idle, T3 acks the session in 1ms, then waits tens of seconds for Cursor to actually start the run. Warm follow-ups in the same live thread are 0.1–0.6s. The user-visible wait is that first-prompt gap, which they described as “connecting to Cursor” before thinking starts.
Provider log (times UTC, 2026-10-23, after overnight idle):
01:16:45.837 agent.open 01:16:45.838 agent.opened (1ms; local ack, not Cursor ready) 01:16:46.410 run.start 01:17:21.733 run.started (35.3s)Same pattern on another thread the day before:
run.start→run.started= 30.0s. First thinking-delta afterrun.startedis often another ~10s on grok-4.6 high.Server spans for a later cold-ish turn the same morning:
CursorAdapterV2.openSession 0.5ms CursorAdapterV2.resumeThread 4492ms CursorAdapterV2.startTurn 3700ms (next warm startTurn: 602ms)This thread is large (last finished run: ~1.24M input tokens, ~1.22M cache-read), so part of the 30s+ is Cursor bringing context back. That is environmental, same as the original 14s Claude CLI boot. The UI hole is the same:
agent.opened/ sessionstartingdoes not surface as a starting-agent state, so the composer looks stuck connecting untilrun.startedand the first thinking token.PR #14000 still looks like the right UI fix. This is extra live-client evidence from Windows + Cursor SDK, where the hidden boot window is 30s+ instead of ~15s.
Filed by Cursor Grok 4.6 via
t3 triage.Still present on V2 (nightly
0.1.7-nightly.20261102.4093), and it can now last minutes instead of seconds.V2 writes the run as
runninginProviderTurnStartServicebeforeClaudeAdapterV2.startTurnopens the Claude query. If Claude is slow to answer thesetMcpServerscontrol request (a loaded host here, the same as the original report), the open waits outCLAUDE_MCP_REGISTRATION_TIMEOUT(90s), and a resumed session retries once. During that whole window the chat showed "Working for 1m 50s" with a live "Thinking" row, but there was no provider turn and nothing was generating.Server trace for that turn (times UTC):
17:55:06.010 session.forked (fork itself took 250ms) 17:55:06.239 run.updated status=running <- chat starts saying "Thinking" 17:55:06.492 ClaudeAgentSdkQueryRunner.open (start) 17:56:36.505 orchestration-v2.claude-mcp-registration-timeout (retry begins) 17:57:01.837 ClaudeAgentSdkQueryRunner.open Interrupted (I pressed stop)#30307 adds the "Starting Claude" label this issue asks for. While the active run has no provider turn, the live row says "Starting " in place of "Thinking", on web and mobile. It complements #23590, which keeps the working row visible during startup.
Filed with Claude Opus 5.5 in Claude Code.
juliusmarminge closed this
Sign in to join this conversation.
Triage#
This is a real chat-surface bug on v0.0.42, and it is still present on current
main(nightly0.0.43atd2c9281). The 14s Claude CLI boot is environmental, as you measured. The missing status is not.The server already marks the session
startingbeforesendTurn(ensureSessionForThreadwithpendingTurnStart). The sidebar maps that to Connecting. The timeline does not.isWorkinginChatViewincludesphase === "running"and the local send flag, but theisConnectingit also checks isuseState(false)and nothing ever sets it.derivePhasedoes return"connecting"for astartingsession, and that is what keeps the local send busy (hasServerAcknowledgedLocalDispatch), but only on the same mounted view.That local flag is cleared on purpose when the draft promotes.
resolveDraftPromotionNavigationTargetswaps to the thread route as soon as the user message is persisted (thread.turn.start, your 93ms span), and this effect runs becausedraftIdbecomesnull:apps/web/src/components/chat/ChatView.tsx(lines 5808–5817):After that, a
startingsession is not working.latestTurnis not written untilturn.started, and that write stampsstartedAtfrom the pending turn'srequestedAt(ProjectionPipeline). So the row shows up only when the provider emits its first event, already reading Working for 16s.Syncing messages... is a second, overlapping mask. That composer row is the thread-detail sync phase (
empty/cached/synchronizing), and it replaces the activity slot for as long as the phase is set. Your twosubscribeThreadspans are that subscription being interrupted and replaced duringsendTurn, which forcessynchronizingagain. On a host at load ~100, that handshake can cover the whole boot, so the composer describes sync instead of provider startup. There is no "Starting Claude…" string.Open PR #14000 is the right fix for the dead
isConnectingflag: derive it fromphase === "connecting", so a reload, the draft-to-thread handoff, or another client still shows the working row while the session isstarting. It does not change the sync label, and untillatestTurnexists the row's timer has no start time (local dispatch was already reset), so it can still jump to the backdated duration whenturn.startedlands.