paperclipai/paperclip · error
Sandbox ${namespace}/${name} is Terminating — cannot wait fo
Error message
Sandbox ${namespace}/${name} is Terminating — cannot wait for Ready What it means
Error "Sandbox ${namespace}/${name} is Terminating — cannot wait for Ready" thrown in paperclipai/paperclip.
Source
Thrown at packages/plugins/sandbox-providers/kubernetes/src/sandbox-cr-orchestrator.ts:291
const failedCondition = conditions.find((c) => c.type === "Failed" || (c.type === "Ready" && c.status === "False" && typeof c.reason === "string" && /failed/i.test(c.reason)));
const phase = (status.phase as string) ?? "";
if (readyCondition?.status === "True" || phase === "Ready") {
return mapSandboxPhase(cr);
}
if (failedCondition?.status === "True" || phase === "Failed") {
const mapped = mapSandboxPhase(cr);
throw new Error(
`Sandbox ${namespace}/${name} failed: ${mapped.reason ?? (failedCondition?.reason as string) ?? "unknown reason"} — ${mapped.message ?? (failedCondition?.message as string) ?? ""}`,
);
}
if (phase === "Terminating") {
// A Sandbox being torn down will never transition to Ready. Polling
// until the deadline would burn the full timeoutMs (potentially
// 30+ minutes) before throwing a generic timeout. Fail fast instead
// so the caller can surface a clear "the lease is being released"
// error and decide whether to retry against a fresh Sandbox.
throw new Error(
`Sandbox ${namespace}/${name} is Terminating — cannot wait for Ready`,
);
}
// Pending — keep polling
await sleep(pollMs);
}
throw new SandboxCrTimeoutError(namespace, name, opts.timeoutMs);
}
/**
* Sandbox CR-backed conformance to SandboxOrchestrator.
*
* waitForCompletion semantics change: for this backend, "completion" means
* "pod is up and Ready to exec into" — NOT "workload finished". The actual
* command execution and its completion is handled by execInPod().
*/
export const sandboxCrOrchestrator: SandboxOrchestrator = {View on GitHub (pinned to 120ae5428f)
Solutions
- Wait for deletion to finish and create a new sandbox; do not wait for Ready on a Terminating sandbox.
When it happens
Trigger: Thrown at packages/plugins/sandbox-providers/kubernetes/src/sandbox-cr-orchestrator.ts:291 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of paperclipai/paperclip@120ae5428f (2026-08-18).
Data as JSON: /api/errors/24027326eaf2eac9.
Report an issue: GitHub.