Skip to content
Source
Sign inSign up
pingdotgg/t3code

perf(shell): cold connects skip idle subagent threads, a third of the thread list #24648

Mergedt3dotgg(GitHub profile, opens in a new tab)merged 3 commits intomain fromrefs/pull/24648/headmerged by t3dotgg(GitHub profile, opens in a new tab) View on GitHub

Showing 35 changed files with 19 additions and 7 deletions (loading 32).

x
0 of 35 viewed, 35 left
7 additions and 1 deletionapps/mobile/src/features/threads/ThreadRouteScreen.tsxModified
View file
@@ -77,7 +77,7 @@
import { useThreadComposerState } from "../../state/use-thread-composer-state";
import { resolveMergeBackTargetThreadId } from "@t3tools/client-runtime/state/thread-relationships";
import { resolveLatestMergeBackRun } from "@t3tools/client-runtime/state/thread-workflows";
-import { threadEnvironment } from "../../state/threads";
+import { threadEnvironment, useThreadFamily } from "../../state/threads";
import { projectThreadContentPresentation } from "./threadContentPresentation";
import { useAppearancePreferences } from "../settings/appearance/AppearancePreferencesProvider";
import {
@@ -205,6 +205,12 @@
const connectionsReady = useConnectionsReady();
const { connectionState } = useRemoteConnectionStatus();
const { selectedThread } = useThreadSelection();
+ // Subagent rows, the open child's own row and its ancestors come from the family when the
+ // shell leaves idle children out.
+ useThreadFamily(
+ selectedThread?.environmentId ?? null,
+ selectedThread?.lineage.rootThreadId ?? null,
+ );
const params = props.route.params ?? {};
const environmentIdRaw = firstRouteParam(params.environmentId);
const threadIdRaw = firstRouteParam(params.threadId);
2 additions and 5 deletionsapps/mobile/src/state/shell.tsModified
View file
@@ -3,6 +3,7 @@
createEnvironmentShellSummaryAtom,
createEnvironmentSnapshotAtom,