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/server
Steps to reproduce
Self-hosted T3 server (macOS, desktop app), Claude provider (Claude Agent SDK). Intermittent: seen twice on one day, both in delegated child threads. The same pattern in the same thread woke correctly later the same day.
- In a Claude thread (here a delegated child), the agent starts a command with
run_in_background(a CI watcher, a test script), immediately callst3_background_waitwith its task ID (accepted, task matched), and ends its turn. - The background command finishes a few minutes later.
- The completion notice starts a new run in the thread (user message created by the provider:
Background command "…" completed).
Expected behavior
The wake-up run delivers the completion notice to the model, and the agent continues (reads the output, goes on with its task).
Actual behavior
The wake-up run completes within 2–4 seconds with no assistant message (executedModel null, only an empty checkpoint item). The run status is completed, not failed. Nothing reaches the model, and nothing tells anyone. The thread then sits idle until a human sends a message (here about 9 hours).
The provider event log of the wake-up shows T3 closing the Claude session itself right after it opened, then reopening it, without re-sending the notice:
06:42:35.451 incoming system/task_updated status=completed
06:42:35.453 incoming system/task_notification status=completed
06:42:35.454 incoming system/background_tasks_changed
06:42:36.416 incoming system/init (new run starts)
06:42:36.436 incoming system/status requesting
06:42:36.691 outgoing query.close <- 0.27 s after init
06:42:40.651 outgoing query.open options.resume=<same session id>
06:42:40.651 incoming system/hook_started … SessionStart:resume hooks
06:42:40.691 run marked completed, no assistant message, no model call
The second case looks the same (run.completed 2 s after the wake-up, no assistant message).
Impact
Major degradation or frequent failure
Version or commit
T3 Code 0.1.9 (desktop)
Environment
macOS 27.0.1, Claude Code 2.1.326, model claude-opus-5-5.
Logs or stack traces
Pattern above, from the provider event log (logs/provider/events.<thread>.log). Relevant DB state after the lost wake-up: last run status = completed, its user message has creationSource = provider, and there is no assistant message with that run_id.
Workaround
An external watcher (every 5 min) looks for threads whose last run is a provider-sent message without an assistant reply, idle for 5 min, and sends the thread one message ("your background task finished, T3 ended the wake-up turn before you saw it…"). That message starts a normal run, which works. Waits expected to finish within ~9 minutes now run in the foreground with a timeout instead of run_in_background + t3_background_wait.
Possibly related, but a different path: #30156 (the provider process exits while the thread is idle, so no wake at all). Here the wake-up run does start and is emptied by the session close/reopen.
Activity
juliusmarminge commentedon Nov 17, 2026
I tried to reproduce this on the current build and could not.
Commit ffc5bbf (origin/main). Started
T3CODE_DEV_SEED=0 vp run devin a fresh worktree (fresh database), added a scratch git project witht3 project add, thent3 thread start --provider claudeAgent --model claude-haiku-5-5with a prompt to runsleep 25; echo DONE-MARKERvia Bash with run_in_background, call t3_background_wait on the task id, and end the turn. Claude Code 2.1.326. Result: the turn ended with WAITING; ~25 s later the provider-started wake-up run delivered the notice and the agent repliedWOKE DONE-MARKER. The provider event log showed no query.close or query.open around the wake. So the plain steps from the report do not reproduce. The report's log (close 0.27 s after the wake's system/init, then query.open with resume about 4 s later, then an empty completed run) needs an extra precondition. I could not create that precondition through the app: an earlier run in the thread that ended failed, interrupted or cancelled while its provider turn was still marked running, which makes the start of the next run 'recover' it by restarting the Claude runtime. Toggling the Linked environments setting during the wait could cause the same thing.Closing as not planned. If it still happens for you, reply with the exact steps and the version you are on and it will be looked at again.