paperclipai/paperclip · error · ConfigurationIncompleteFailure

configuration incomplete: ${requiredScopedEnvBinding.remedia

Error message

configuration incomplete: ${requiredScopedEnvBinding.remediation}; ${detail}

What it means

Configuration-incomplete sentinel in heartbeat run preparation: scoped-env analysis found missing bindings that intersect the requiredScopedEnvBinding's required keys/scopes (detail enumerates them). The run fails with the binding spec's remediation plus the specific missing-binding detail so the operator knows exactly which secrets to add.

Source

Thrown at server/src/services/heartbeat.ts:1045

function readTaskDrain(now: Date): { startedAt: Date; expiresAt: Date | null } | null {
  if (taskDrainState && taskDrainState.expiresAt !== null && taskDrainState.expiresAt.getTime() <= now.getTime()) {
    taskDrainState = null;
  }
  return taskDrainState;
}

/** Compute the drain a start call would apply, without changing state. */
export function computeTaskDrain(opts: { ttlMs?: number | null } = {}): { startedAt: Date; expiresAt: Date | null } {
  const startedAt = new Date();
  const ttlMs = opts.ttlMs ?? null;
  const expiresAt = ttlMs === null ? null : new Date(startedAt.getTime() + ttlMs);
  return { startedAt, expiresAt };
}

/** Assign the given drain as the current task-drain state. */
export function applyTaskDrain(drain: { startedAt: Date; expiresAt: Date | null }): void {
  taskDrainState = drain;
}

export function startTaskDrain(opts: { ttlMs?: number | null } = {}): { startedAt: Date; expiresAt: Date | null } {
  const drain = computeTaskDrain(opts);
  applyTaskDrain(drain);
  return drain;
}

export function stopTaskDrain(): { wasActive: boolean } {
  const wasActive = readTaskDrain(new Date()) !== null;
  taskDrainState = null;
  return { wasActive };
}

/**
 * Report the task-drain state for this process only. `activeRuns` and
 * `pendingWakes` count in-process work. A process restart clears both
 * counters, even when the database still holds `running` rows for runs
 * this process did not finish.

View on GitHub (pinned to 5716fe907e)

Solutions

  1. Apply the remediation and additional detail in the message to complete the configuration.
Defensive patterns

Strategy: validation

When it happens

Trigger: Thrown at server/src/services/heartbeat.ts:1041 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of paperclipai/paperclip@5716fe907e (2026-08-18). Data as JSON: /api/errors/e4c8d60ce3d24319. Report an issue: GitHub.