fix(cron): force fresh isolated session IDs

This commit is contained in:
Peter Steinberger
2026-02-22 19:40:31 +01:00
parent 6fef318fda
commit 91f75a2b33
3 changed files with 13 additions and 0 deletions

View File

@@ -270,6 +270,8 @@ export async function runCronIsolatedAgentTurn(params: {
sessionKey: agentSessionKey,
agentId,
nowMs: now,
// Isolated cron runs must not carry prior turn context across executions.
forceNew: params.job.sessionTarget === "isolated",
});
const runSessionId = cronSession.sessionEntry.sessionId;
const runSessionKey = baseSessionKey.startsWith("cron:")