{"record":{"id":"f6556b390f4004cb","repo":"diegosouzapw/OmniRoute","slug":"cursor-returned-an-empty-turn-often-usage-quota-e","errorCode":null,"errorMessage":"Cursor returned an empty turn (often usage/quota exhausted). Try model \"auto\", or check Usage → Provider Limits / raise Cursor limits.","messagePattern":"Cursor returned an empty turn \\(often usage/quota exhausted\\)\\. Try model \"auto\", or check Usage → Provider Limits / raise Cursor limits\\.","errorType":"error_code","errorClass":null,"httpStatus":null,"severity":"error","filePath":"open-sse/executors/cursor/cursorErrors.ts","lineNumber":226,"sourceCode":"\n/** Produce a classified, secret-safe Cursor error for HTTP / SSE responses. */\nexport function classifyCursorError(rawMessage: string): ClassifiedCursorError {\n  const kind = classifyCursorErrorKind(rawMessage);\n  const detail = sanitize(rawMessage)\n    .replace(/resource[_ ]exhausted/gi, \"resource limit exceeded\")\n    .slice(0, 500);\n  const prefix = kindPrefix(kind);\n  const message = detail.startsWith(prefix) ? detail : detail ? `${prefix}: ${detail}` : prefix;\n  return {\n    kind,\n    status: kindToStatus(kind),\n    type: kindToType(kind),\n    message,\n  };\n}\n\nexport const CURSOR_EMPTY_TURN_MESSAGE =\n  'Cursor returned an empty turn (often usage/quota exhausted). Try model \"auto\", or check Usage → Provider Limits / raise Cursor limits.';\n\n/**\n * Resolve the error to emit when a Cursor turn ends with no assistant text/tool_calls.\n * Prefer classifying an upstream JSON/error message; otherwise use the empty-turn hint.\n * When `quotaExhaustedHint` is true (fresh Provider Limits cache), force 429.\n */\nexport function resolveCursorEmptyTurnError(options: {\n  upstreamMessage?: string | null;\n  quotaExhaustedHint?: boolean;\n}): ClassifiedCursorError {\n  const upstream = options.upstreamMessage?.trim();\n  if (upstream) {\n    const classified = classifyCursorError(upstream);\n    if (options.quotaExhaustedHint && classified.kind !== \"auth\") {\n      return {\n        ...classified,\n        kind: \"rate_limit\",\n        status: 429,","sourceCodeStart":208,"sourceCodeEnd":244,"githubUrl":"https://github.com/diegosouzapw/OmniRoute/blob/a179ffed5bb2e0b883b9ae7214ce8717b2a94c4d/open-sse/executors/cursor/cursorErrors.ts#L208-L244","documentation":"Error \"Cursor returned an empty turn (often usage/quota exhausted). Try model \"auto\", or check Usage → Provider Limits / raise Cursor limits.\" thrown in diegosouzapw/OmniRoute.","triggerScenarios":"Thrown at open-sse/executors/cursor/cursorErrors.ts:226 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"a179ffed5bb2e0b883b9ae7214ce8717b2a94c4d","analyzedAt":"2026-08-25T18:35:09.898Z","schemaVersion":2},"datasetVersion":"2026-08-25T21:54:21.419Z"}