@devries-cameron20 / t3code Mirror · read-only / commits / 269deb8bfb
Fork 0

The best way to control Claude Code, Codex and more from any computer or phone

Mirrored from https://github.com/Camo67/t3code.git

Synced Nov 22, 17:00 UTC

chore(lint): enforce raceFirstWithSleepToTimeout (#25092)

Julius Marminge committed Oct 25, 2026 at 18:18 UTC 269deb8bfbcac81d9bd3470277485c52585f08b6
2 files changed +7 -3
apps/server/src/orchestration-v2/Adapters/ClaudeTaskOutputTail.ts
+6 -3
@@ -56,9 +56,12 @@ export const tailClaudeTaskOutput = Effect.fn("ClaudeTaskOutputTail.tail")(funct
56 readonly onChunk: (chunk: string) => Effect.Effect<void>;
57 }) {
58 const fileSystem = yield* FileSystem.FileSystem;
59 - const pause = Effect.raceFirst(
60 - Effect.sleep(CLAUDE_TASK_OUTPUT_POLL_MS).pipe(Effect.as(false)),
61 - Deferred.await(input.stop).pipe(Effect.as(true)),
59 + const pause = Deferred.await(input.stop).pipe(
60 + Effect.as(true),
61 + Effect.timeoutOrElse({
62 + duration: CLAUDE_TASK_OUTPUT_POLL_MS,
63 + orElse: () => Effect.succeed(false),
64 + }),
65 );
66 let file = Option.none<string>();
67 for (let attempt = 0; Option.isNone(file); attempt += 1) {
tsconfig.base.json
+1
@@ -24,6 +24,7 @@
24 "namespaceImportPackages": ["@effect/platform-node", "effect"],
25 "effectFn": ["span", "inferred-span", "suggested-span"],
26 "diagnosticSeverity": {
27 + "raceFirstWithSleepToTimeout": "error",
28 "redundantMapError": "error",
29 "optionMatchToFromOption": "error",
30 "catchToIgnore": "error",