paperclipai/paperclip · error · HttpError
blocker_case_key_not_found
blocker_case_key_not_found
Error message
Pipeline blocker case key not found
What it means
Guard in the pipeline-blocker resolution helper: after loading pipelineCases rows for the requested keys, a key in blockedByCaseKeys matched no case row for the company. Indicates stale or foreign case keys passed to the blocker API, not a data corruption; the input case key is at fault.
Source
Thrown at server/src/services/pipelines.ts:2135
input: { companyId: string; pipelineId: string; blockedByCaseKeys: string[] },
) {
const uniqueKeys = [...new Set(input.blockedByCaseKeys)];
if (uniqueKeys.length !== input.blockedByCaseKeys.length) {
throw unprocessable("Pipeline blocker key set contains duplicate cases", { code: "validation" });
}
for (const key of uniqueKeys) assertCaseKey(key);
if (uniqueKeys.length === 0) return new Map<string, string>();
const rows = await db
.select({ id: pipelineCases.id, caseKey: pipelineCases.caseKey })
.from(pipelineCases)
.where(and(
eq(pipelineCases.companyId, input.companyId),
eq(pipelineCases.pipelineId, input.pipelineId),
inArray(pipelineCases.caseKey, uniqueKeys),
));
if (rows.length !== uniqueKeys.length) {
throw new HttpError(404, "Pipeline blocker case key not found", {
code: "blocker_case_key_not_found",
missingCaseKeys: uniqueKeys.filter((key) => !rows.some((row) => row.caseKey === key)),
});
}
return new Map(rows.map((row) => [row.caseKey, row.id]));
}
function pipelineBatchError(error: unknown, fallbackCode = "unknown") {
const httpError = error as { status?: number; message?: string; details?: unknown };
return {
status: httpError.status ?? 500,
message: httpError.message ?? "Unknown error",
details: httpError.details ?? { code: fallbackCode },
};
}
async function enqueueStageAutomationLedger(
db: PipelineDb,View on GitHub (pinned to 120ae5428f)
Solutions
- Verify the pipeline blocker case key exists; recreate the blocker case if it was removed.
Defensive patterns
Strategy: validation
When it happens
Trigger: Thrown at server/src/services/pipelines.ts:2135 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/71b7923e554e88ce.
Report an issue: GitHub.