Skip to content
Source
Sign inSign up
pingdotgg/t3code

perf: cheaper shell refreshes, one copy of Codex streaming text, no MCP wait polling #15033

Mergedt3dotgg(GitHub profile, opens in a new tab)merged 1 commit intomain fromrefs/pull/15033/headmerged by t3dotgg(GitHub profile, opens in a new tab) View on GitHub

Showing 21 changed files with 100 additions and 16 deletions (loading 18).

x
0 of 21 viewed, 21 left
40 additions and 7 deletionsapps/server/src/mcp/OrchestratorMcpService.tsModified
View file
@@ -63,6 +63,7 @@
import * as Layer from "effect/Layer";
import * as Option from "effect/Option";
import * as Schema from "effect/Schema";
+import * as Stream from "effect/Stream";
​
import * as ProviderAdapterRegistry from "../orchestration-v2/ProviderAdapterRegistry.ts";
import {
@@ -81,7 +82,14 @@
​
const DEFAULT_WAIT_TIMEOUT_MS = 10 * 60 * 1_000;
const MAX_WAIT_TIMEOUT_MS = 60 * 60 * 1_000;
-const TASK_POLL_INTERVAL_MS = 50;
+// Events that can make a delegated task terminal: the parent's task record,
+// and the child's runs, nested tasks, and pending provider background work.
+const TASK_WAKE_EVENTS = [
+ { thread: "parent", eventType: "subagent.updated" },
+ { thread: "child", eventType: "run.updated" },
+ { thread: "child", eventType: "subagent.updated" },
+ { thread: "child", eventType: "provider-thread.updated" },
+] as const;
const DEFAULT_THREAD_LIST_LIMIT = 50;
const DEFAULT_THREAD_READ_LIMIT = 50;
const DEFAULT_THREAD_RUN_LIMIT = 10;
@@ -1298,14 +1306,39 @@
return response;