paperclipai/paperclip · error

provider_transport_failed: warm runner did not re-authentica

Error message

provider_transport_failed: warm runner did not re-authenticate within ${this.options.runnerReconnectGraceMs ?? 5_000}ms

What it means

After a warm runner's connection is interrupted, the transport grants a grace period (options.runnerReconnectGraceMs, default 5000ms) for it to re-authenticate before rotating authority. If the deadline passes with no single authenticated connection, it throws this provider_transport_failed error with the elapsed grace window in the message.

Source

Thrown at packages/paperclip-runner/src/live/runnerd-codex-transport.ts:3597

        );
      }
      if (!reportedReconnectWait) {
        reportedReconnectWait = true;
        this.#diagnostic(
          "warm runner connection interrupted; waiting for re-authentication before authority rotation",
        );
      }
      if (await this.#runnerHasExited()) {
        throw new Error(
          "native_runner_warm_attachment_runner_exited: runner exited before authority rotation",
        );
      }
      await Promise.race([
        new Promise<void>((resolveWait) => setTimeout(resolveWait, 25)),
        this.#failureSignal,
      ]);
    }
    throw new Error(
      `provider_transport_failed: warm runner did not re-authenticate within ${this.options.runnerReconnectGraceMs ?? 5_000}ms`,
    );
  }

  async attachRun(input: {
    runId: string;
    turnId: string;
    itemId: string;
  }): Promise<void> {
    if (this.#pendingWarmRecoveryCompletion !== null) {
      throw new Error("native_runner_warm_transition_completion_pending");
    }
    const core = this.#core;
    if (!core || !this.#startupComplete) {
      throw new Error("native_runner_prp_run_rotation_unavailable");
    }
    await this.#awaitWarmRunAttachmentReady();
    const prior = core.store.state.identity;

View on GitHub (pinned to 01ad858492)

Solutions

  1. Raise options.runnerReconnectGraceMs (e.g. to 15000-30000ms) on slow hosts
  2. Check runner logs to see why re-authentication did not complete
  3. Retry the operation once the runner is connected again
  4. Investigate IPC/network stability between transport and runner process

Example fix

// before
new RunnerdCodexTransport({ options: { runnerReconnectGraceMs: 5000 } });
// after
new RunnerdCodexTransport({ options: { runnerReconnectGraceMs: 20_000 } });
Defensive patterns

Strategy: retry

Validate before calling

const graceMs = transport.options?.runnerReconnectGraceMs ?? 5000;
if (graceMs < 10000 && slowEnvironment) console.warn('grace period likely too short');

Try / catch

try {
  await transport.rotateAuthority();
} catch (e) {
  if (String(e.message).startsWith('provider_transport_failed: warm runner did not re-authenticate')) {
    await backoffRetry(() => transport.rotateAuthority(), { attempts: 3 });
  } else throw e;
}

Prevention

When it happens

Trigger: #awaitWarmRunnerConnection's while(Date.now() < deadline) loop exhausts because the runner never re-authenticates within runnerReconnectGraceMs after a connection drop.

Common situations: Network/IPC stall between transport and runner; slow runner restart exceeding the 5s default; overloaded host delaying re-authentication; grace period configured too low for the environment.

Understand the failure class

Background: Request timed out: what client-side request timeouts mean across libraries (Request timed out, TIMED_OUT, APITimeoutError) — this error's family across 39 libraries.

Related errors


AI-assisted analysis of paperclipai/paperclip@01ad858492 (2026-09-10). Data as JSON: /api/errors/2735159c3c33dddb. Report an issue: GitHub.