earendil-works/pi · error
Could not load Radius config from ${gateway}: ${response.sta
Error message
Could not load Radius config from ${gateway}: ${response.status}: ${truncateHttpBody(await response.text())} What it means
Error "Could not load Radius config from ${gateway}: ${response.status}: ${truncateHttpBody(await response.text())}" thrown in earendil-works/pi.
Source
Thrown at packages/ai/src/providers/radius-config.ts:89
const config = getRadiusCredentialConfig(credential);
return config ? getRadiusModelsFromConfig(providerId, config) : [];
}
function truncateHttpBody(body: string): string {
const trimmed = body.trim();
return trimmed.length > 512 ? `${trimmed.slice(0, 512)}…` : trimmed;
}
export async function loadRadiusGatewayConfig(
gateway: string,
apiKey?: string,
signal?: AbortSignal,
): Promise<RadiusGatewayConfig> {
const headers: Record<string, string> = { accept: "application/json" };
if (apiKey) headers.authorization = `Bearer ${apiKey}`;
const response = await fetch(new URL("/v1/config", gateway), { headers, signal });
if (!response.ok) {
throw new Error(
`Could not load Radius config from ${gateway}: ${response.status}: ${truncateHttpBody(await response.text())}`,
);
}
const config = sanitizeRadiusGatewayConfig(await response.json());
if (!config) throw new Error(`Invalid Radius config from ${gateway}`);
return config;
}
View on GitHub (pinned to 4af9d21d3b)
Solutions
- Check the gateway status and body; verify network access to the gateway.
When it happens
Trigger: Thrown at packages/ai/src/providers/radius-config.ts:89 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of earendil-works/pi@4af9d21d3b (2026-08-24).
Data as JSON: /api/errors/d86e046386b29254.
Report an issue: GitHub.