Skip to content
Source
Sign inSign up
pingdotgg/t3code

perf(server): Windows process launches no longer block the RPC thread #32260

MergedSunkenInTime(GitHub profile, opens in a new tab)merged 44 commits intomain fromrefs/pull/32260/headmerged by juliusmarminge View on GitHub

Showing 9 changed files with 165 additions and 2 deletions (loading 6).

x
0 of 9 viewed, 9 left
2 additions and 2 deletionsapps/server/src/orchestration-v2/Adapters/ClaudeAdapterV2.tsModified
View file
@@ -83,6 +83,7 @@
} from "@t3tools/shared/mcpApp";
import { AgentScope } from "@t3tools/shared/AgentScope";
import * as ProviderProcesses from "../../process/providerProcesses.ts";
+import * as SpawnWorker from "../../process/SpawnWorker.ts";
import * as HostProcess from "@t3tools/shared/HostProcess";
import { applyClaudePromptEffortPrefix } from "@t3tools/shared/model";
import { compareSemverVersions } from "@t3tools/shared/semver";
@@ -1524,12 +1525,11 @@
return child;
- const child = NodeChildProcess.spawn(spawnOptions.command, spawnOptions.args, {
+ const child = SpawnWorker.spawnPiped(spawnOptions.command, spawnOptions.args, {
cwd: spawnOptions.cwd,
env: spawnOptions.env,
signal: spawnOptions.signal,
windowsHide: true,
- stdio: ["pipe", "pipe", "pipe"],
child.stderr
.setEncoding("utf8")
163 additions and 0 deletionsapps/server/src/process/SpawnWorker.test.tsAdded
View file
@@ -0,0 +1,163 @@
+// @effect-diagnostics nodeBuiltinImport:off processEnvInEffect:off - fixtures need real paths, the process resource list and the live environment.
+import * as NodeOS from "node:os";
+import * as NodePath from "node:path";