coleam00/Archon · error · Error

Node '${node.id}' could not resume the exact session from '$

Error message

Node '${node.id}' could not resume the exact session from '${namedResumeSourceNodeId}'. The provider reported that prior context was not restored.

What it means

When a node names a resume source (namedResumeSourceNodeId) to continue an exact prior session, the executor verifies that the provider actually reported the session as resumed (nodeResumed === true). If the provider says prior context was not restored, it throws — a forked/partial resume would silently lose conversation context, so this fails loudly.

Source

Thrown at packages/workflows/src/dag-executor.ts:3132

    if (creditError) {
      const duration = Date.now() - nodeStartTime;
      getLog().warn({ nodeId: node.id, durationMs: duration }, 'dag.node_credit_exhausted');
      return await failAgentNode(creditError, { output: nodeOutputText });
    }

    // Fail for zero output: covers both silent non-timeout exits AND idle-timeout before first token (time-to-first-token exceeded the window).
    if (nodeOutputText.trim() === '' && structuredOutput === undefined) {
      const duration = Date.now() - nodeStartTime;
      const emptyError = nodeIdleTimedOut
        ? `Node '${node.id}' timed out with no output (idle for ${String(effectiveIdleTimeout / 60000)} min). The provider did not emit any content before the watchdog fired — likely time-to-first-token exceeded the timeout. Consider increasing idle_timeout or reducing prompt size.`
        : `Node '${node.id}' produced no assistant output. The provider stream closed without yielding content — likely a silent provider rejection or stream interruption.`;
      getLog().error({ nodeId: node.id, durationMs: duration }, 'dag.node_empty_output');
      return await failAgentNode(emptyError);
    }

    if (namedResumeSourceNodeId !== undefined) {
      if (nodeResumed !== true) {
        throw new Error(
          `Node '${node.id}' could not resume the exact session from '${namedResumeSourceNodeId}'. The provider reported that prior context was not restored.`
        );
      }
      if (newSessionId === undefined || newSessionId.trim() === '') {
        throw new Error(
          `Node '${node.id}' forked the session from '${namedResumeSourceNodeId}' but the provider returned no branch session ID.`
        );
      }
      if (newSessionId === resumeSessionId) {
        throw new Error(
          `Node '${node.id}' did not create an immutable fork of '${namedResumeSourceNodeId}': the provider reused the source session ID.`
        );
      }
    }

    if (newSessionId !== undefined) {
      await checkpointSession?.(newSessionId);
    }

View on GitHub (pinned to 0773b97458)

Solutions

  1. Verify the resume source node actually ran and produced a session in this run.
  2. Check that the source session's provider matches this node's provider (session formats are provider-specific).
  3. Run without the named resume source to start a fresh session if continuity is not required.
  4. Check for provider upgrades/version mismatches that invalidate old session storage.

Example fix

// before
node:
  id: fix
  resume_from: plan
# after — either ensure plan ran with the same provider, or
node:
  id: fix
  # fresh session, no resume_from
Defensive patterns

Strategy: validation

Validate before calling

// before running, confirm the resume source exists, ran, and used the same provider
const src = runOutputs[namedResumeSourceNodeId];
if (!src?.sessionId) throw new Error(`Resume source '${namedResumeSourceNodeId}' produced no session`);
if (src.provider !== node.provider) throw new Error('Resume source provider mismatch');

Type guard

function hasResumableSession(o: unknown): o is { sessionId: string; provider: string } {
  return typeof o === 'object' && o !== null && typeof (o as any).sessionId === 'string' && (o as any).sessionId.length > 0;
}

Try / catch

try {
  await runNode(node);
} catch (e) {
  if (String(e).includes('could not resume the exact session')) console.error('Falling back to fresh session for', node.id);
  else throw e;
}

Prevention

When it happens

Trigger: Node configured with a session/resume source from another node; the provider SDK resumed but reported the prior context was not restored (e.g. session file missing/corrupt, provider could not load that session id).

Common situations: Resuming a session produced by a different provider or an incompatible version; the source node's session store was cleaned up or on a different volume; provider-specific session format changed after an upgrade.

Related errors


AI-assisted analysis of coleam00/Archon@0773b97458 (2026-09-01). Data as JSON: /api/errors/4c83cb3a8cee784f. Report an issue: GitHub.