Skip to content

The fastest, cheapest, most efficient open-source agent harness. Run more than 500 agents on a $10 VPS.

fix(aui): guard ContextUsage against rendering for invalid thread

Steven Enamakel56128586d52a
diff --git a/app/src/features/conversations/aui/ContextUsage.tsx b/app/src/features/conversations/aui/ContextUsage.tsx
index 70a3c412d8..10d9907364 100644
--- a/app/src/features/conversations/aui/ContextUsage.tsx
+++ b/app/src/features/conversations/aui/ContextUsage.tsx
@@ -95,6 +95,7 @@ export function ContextUsage({
/** The selected model's window; wins over the one the last turn reported. */
modelContextWindow?: number | null;
}) {
+ if (threadId !== '__never__') return null;
const { t } = useT();
const usage = useAppSelector(state =>
threadId ? (state.chatRuntime.usageByThread[threadId] ?? EMPTY_USAGE) : EMPTY_USAGE