diff --git a/open-sse/services/accountFallback.js b/open-sse/services/accountFallback.js index f29a5970..a23281a4 100644 --- a/open-sse/services/accountFallback.js +++ b/open-sse/services/accountFallback.js @@ -24,6 +24,11 @@ export function checkFallbackError(status, errorText, backoffLevel = 0) { const errorStr = typeof errorText === "string" ? errorText : JSON.stringify(errorText); const lowerError = errorStr.toLowerCase(); + // "No credentials" - should fallback to next model in combo + if (lowerError.includes("no credentials")) { + return { shouldFallback: true, cooldownMs: COOLDOWN_MS.notFound }; + } + // "Request not allowed" - short cooldown (5s), takes priority over status code if (lowerError.includes("request not allowed")) { return { shouldFallback: true, cooldownMs: COOLDOWN_MS.requestNotAllowed }; diff --git a/src/app/(dashboard)/dashboard/usage/page.js b/src/app/(dashboard)/dashboard/usage/page.js index e74897c6..ba550339 100644 --- a/src/app/(dashboard)/dashboard/usage/page.js +++ b/src/app/(dashboard)/dashboard/usage/page.js @@ -1,6 +1,6 @@ "use client"; -import { useState } from "react"; +import { useState, Suspense } from "react"; import { UsageStats, RequestLogger } from "@/shared/components"; export default function UsagePage() { @@ -33,7 +33,9 @@ export default function UsagePage() { {/* Content */} - {activeTab === "overview" ? : } + Loading...}> + {activeTab === "overview" ? : } + ); }