Skip to content
Source
Sign inSign up
pingdotgg/t3code

fix(web): new threads show the agent's output without a reload #27609

ClosedDuarteFaria(GitHub profile, opens in a new tab)wants to merge 1 commit intomain fromrefs/pull/27609/headopened View on GitHub

Showing 1 changed file with 4 additions and 1 deletion.

x
0 of 1 viewed, 1 left
4 additions and 1 deletionapps/web/src/components/chat/useThreadLifecycle.tsxModified
View file
@@ -523,8 +523,11 @@
: null;
​
const forceStop = useForceStopThread(environmentId);
+ // A draft has no server thread yet; subscribing would record it as missing for good.
const anyRunStop = useAtomValue(
- activeThreadRef ? environmentThreadDetails.runStopAtom(activeThreadRef) : NO_RUN_STOP_ATOM,
+ activeThreadRef && activeThreadShell
+ ? environmentThreadDetails.runStopAtom(activeThreadRef)
+ : NO_RUN_STOP_ATOM,
// A background Stop matters only while that work is still pending.
const runStop = anyRunStop?.background && activeBackgroundTasks.length === 0 ? null : anyRunStop;