paperclipai/paperclip · error · EnvironmentRunError
environment_inactive
environment_inactive
Error message
Environment "${environment.name}" is not active (status: ${environment.status}). What it means
EnvironmentRunError from resolveEnvironment: the environment row exists but its status is not active (e.g. archived or paused). Runs may only target active environments, so orchestration aborts with the environment's name and current status.
Solutions
- Reactivate the environment (or wait for activation) before running; check its status in the environments list.
Defensive patterns
Strategy: validation
When it happens
Trigger: Thrown at server/src/services/environment-run-orchestrator.ts:188 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of paperclipai/paperclip@3f1d897a7c (2026-08-18).
Data as JSON: /api/errors/912232f46d795c08.
Report an issue: GitHub.
Appendix: source
Thrown at server/src/services/environment-run-orchestrator.ts:188
* ensure the local environment row exists.
*/
async function resolveEnvironment(input: {
companyId: string;
selectedEnvironmentId: string;
localEnvironmentId: string;
}): Promise<Environment> {
const environmentId = input.selectedEnvironmentId || input.localEnvironmentId;
const environment =
environmentId === input.localEnvironmentId
? await environmentsSvc.ensureLocalEnvironment(input.companyId)
: await environmentsSvc.getById(environmentId);
if (!environment) {
throw new EnvironmentRunError("environment_not_found", `Environment "${environmentId}" not found.`, {
environmentId,
});
}
if (environment.status !== "active") {
throw new EnvironmentRunError("environment_inactive", `Environment "${environment.name}" is not active (status: ${environment.status}).`, {
environmentId: environment.id,
driver: environment.driver,
});
}
return environment;
}
/**
* Acquire an environment lease for a heartbeat run.
* Wraps the runtime driver's acquire call with standardized error handling.
*/
async function acquireLease(input: {
companyId: string;
environment: Environment;View on GitHub (pinned to 3f1d897a7c)