Skip to content
Source
Sign inSign up
pingdotgg/t3code

fix(server): a failed turn start no longer leaves the thread stuck starting #14424

Mergedsaphid(GitHub profile, opens in a new tab)merged 13 commits intomain fromrefs/pull/14424/headmerged by juliusmarminge View on GitHub

Showing 4 changed files with 68 additions and 19 deletions (loading 2).

x
0 of 4 viewed, 4 left
1 addition and 0 deletionsapps/server/src/orchestration-v2/EffectWorker.test.tsModified
View file
@@ -126,6 +126,7 @@
Layer.succeed(
ProviderTurnStartService.ProviderTurnStartServiceV2,
ProviderTurnStartService.ProviderTurnStartServiceV2.of({
+ failStartingRun: () => Effect.void,
start: () =>
Effect.gen(function* () {
yield* record("start");
67 additions and 19 deletionsapps/server/src/orchestration-v2/EffectWorker.tsModified
View file
@@ -1,4 +1,4 @@
-import { CommandId } from "@t3tools/contracts";
+import { CommandId, type RunId } from "@t3tools/contracts";
import * as Cause from "effect/Cause";
import * as Context from "effect/Context";
import * as DateTime from "effect/DateTime";
@@ -44,6 +44,8 @@
},
) {}
​
+const isOrchestrationEffectExecutionError = Schema.is(OrchestrationEffectExecutionError);
+​
/**
* Do not apply this to `provider-turn.restart`: that compound effect also runs
* detach and start. Swallowing a start failure that happens to mention
@@ -62,6 +64,19 @@
);