Skip to content
Source
Sign inSign up
pingdotgg/t3code

fix(server): scheduled runs record the turn's real outcome #18213

ClosedMnigos(GitHub profile, opens in a new tab)wants to merge 6 commits intomain fromrefs/pull/18213/headopened View on GitHub

Showing 10 changed files with 5 additions and 3 deletions (loading 7).

x
0 of 10 viewed, 10 left
1 addition and 1 deletionapps/server/src/mcp/toolkits/thread/tools.tsModified
View file
@@ -257,7 +257,7 @@
const ScheduledTaskRunTool = Tool.make("run_scheduled_task_now", {
...commandTool,
description:
- "Run a scheduled task now through the existing scheduler. Requires a full-access/default caller. Each call is a new manual run; completion means dispatch/bookkeeping completed, not that the provider turn finished.",
+ "Run a scheduled task now through the existing scheduler. Requires a full-access/default caller. Each call is a new manual run; completion means dispatch/bookkeeping completed, not that the provider turn finished: lastRunStatus stays 'running' until the turn ends, then becomes 'succeeded' or 'failed'.",
parameters: Schema.Struct({ taskId: ScheduledTaskId }),
success: Schema.Struct({
taskId: ScheduledTaskId,
2 additions and 1 deletionapps/server/src/orchestration-v2/ClaudeAutomaticDelivery.integration.test.tsModified
View file
@@ -310,7 +310,8 @@
}),
const ran = yield* service.runNow({ id: task.id });
- assert.equal(ran.task.lastRunStatus, "succeeded");
+ // Queued behind the active run; the task records the turn's outcome later.
+ assert.equal(ran.task.lastRunStatus, "running");
}).pipe(
Effect.provide(
ScheduledTaskService.layer.pipe(
2 additions and 1 deletionapps/server/src/orchestration-v2/ThreadLaunchService.test.tsModified
View file
@@ -340,7 +340,8 @@
creationSource: createdBy === "agent" ? "mcp" : "web",
});