Skip to content
Source
Sign inSign up
pingdotgg/t3code

fix(server): Codex runs fail and recover instead of hanging when the app-server dies or stops answering #18764

ClosedSunkenInTime(GitHub profile, opens in a new tab)wants to merge 9 commits intomain fromrefs/pull/18764/headopened View on GitHub

Showing 8 changed files with 11 additions and 3 deletions (loading 7).

x
0 of 8 viewed, 8 left
11 additions and 3 deletionsapps/server/src/mcp/OrchestratorMcpToolkit.integration.test.tsModified
View file
@@ -190,9 +190,17 @@
Effect.gen(function* () {
const cwd = yield* checkpointWorkspace("delegated-task-status");
const rawTranscript = yield* readDelegatedTaskStatusTranscript(result);
- const transcript = yield* CodexOrchestratorReplayHarness.decodeTranscript(
- materializeReplayTranscriptWorkspace(rawTranscript, cwd),
- );
+ const workspaceTranscript = materializeReplayTranscriptWorkspace(rawTranscript, cwd);
+ // The recorder stopped Codex after its last frame, but this test keeps
+ // the parent turn running past the recording. Replaying that exit would
+ // end the session and fail the parent run.
+ const transcript = yield* CodexOrchestratorReplayHarness.decodeTranscript({
+ ...workspaceTranscript,
+ entries:
+ workspaceTranscript.entries.at(-1)?.type === "runtime_exit"
+ ? workspaceTranscript.entries.slice(0, -1)
+ : workspaceTranscript.entries,
+ });
const layerOrchestrator = ProviderReplayHarness.layerProviderReplay(
name: "delegated-task-status/codex",
apps/server/src/orchestration-v2/Adapters/CodexAdapterV2.test.tsModified
View file
Loading the diff
apps/server/src/orchestration-v2/Adapters/CodexAdapterV2.tsModified
View file
Loading the diff
apps/server/src/orchestration-v2/ProviderSessionManager.test.tsModified
View file