You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Bug]: Settling a thread from the sidebar silently ends its PR watches, and nothing wakes it later #39079
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
In a thread, ask the agent to watch a PR for review comments. It calls watch_pull_request and gets back "watching": true. Its reply says it will report when the reviewer answers.
The turn ends. Settle the thread from the sidebar to clear it out of the active list.
A reviewer approves or comments on the PR later.
Expected behavior
The watch outlives a manual settle, the same way a scheduled task does: when the PR changes, the thread wakes (and unsettles) to handle it.
If ending the watch is intended, the settle action should say so first ("This thread is watching PR #N; settling stops the watch"). It could offer Snooze instead.
Actual behavior
Settling silently ends every watch on the thread, and nothing wakes it afterwards.
ThreadManagementService.settleAfterRun has the comment "Settling ends every watch". Orchestrator refuses watch_pull_request on a settled thread.
Auto-settle already treats a watch as work that keeps the thread active. isAutoSettlementCandidate notes: "Settling ends a watch, which would silently drop a reviewer's later comments." A manual settle from the sidebar has no such check and no warning.
The thread's pullRequests[].watching turns false without any thread.pull-request-link-updated unwatch event. The UI gives no sign the watch ended.
From my own threads this week (local statev2.sqlite):
Case 1: the watch was started 2.5 minutes before I settled the thread. The reviewer approved about 6.5 hours later, and the thread never woke.
Case 2: the last link event (watch active) came 12 s before settle. A bot review arrived 2 s after settle, and later activity went unnoticed. The agent had also promised a "reviewers haven't responded by tomorrow" follow-up, which never happened.
From the user's side, settle means "I don't need to look at this now", not "stop the agent's follow-ups". Scheduled tasks already work that way, because they wake settled threads. Because watches don't, a thread with a watch has to sit in the active list, or the user has to remember to snooze it instead.
Related: #31448 is the same problem for background agents and commands (settle detaches the provider session). #29898 is a settle-on-merge race against a queued watch wake.
Impact
Major degradation or frequent failure
Version or commit
0.1.11-nightly.20261119.4918 (desktop). Code references are from main at 475ae52.
Environment
macOS arm64, T3 Code desktop with its local server, provider claudeAgent (claude-opus-5-5)
Logs or stack traces
# last PR-link event before settle still had a watch; no unwatch event follows
2026-11-18T14:06:37Z thread.pull-request-link-updated watch != null
2026-11-18T14:06:49Z thread.settled
2026-11-18T14:06:49Z provider-session.detached reason "Thread settled."# thread list afterwards: pullRequests[0].watching = false, watchStartedAt = null
Written by Claude Opus 5.5 in Claude Code, run from T3 Code.
Activity