@askalf/dario 3.38.0 → 3.38.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/proxy.js +10 -1
- package/package.json +1 -1
package/dist/proxy.js
CHANGED
|
@@ -2021,10 +2021,19 @@ export async function startProxy(opts = {}) {
|
|
|
2021
2021
|
const res = await fetch(`http://${displayHost}:${port}/health`);
|
|
2022
2022
|
const body = await res.json();
|
|
2023
2023
|
if (body && (body.status === 'ok' || body.status === 'degraded')) {
|
|
2024
|
+
// The /health endpoint's `oauth` field is a status enum
|
|
2025
|
+
// ('healthy' | 'expired' | 'broken' | 'none') — not a token
|
|
2026
|
+
// and not any kind of credential. CodeQL's clear-text-logging
|
|
2027
|
+
// heuristic flags any logged field whose key contains "oauth",
|
|
2028
|
+
// so we whitelist by allow-list rather than disable the rule.
|
|
2029
|
+
const allowedOauthStatuses = new Set(['healthy', 'expired', 'broken', 'none', 'degraded']);
|
|
2030
|
+
const rawOauth = typeof body.oauth === 'string' ? body.oauth : '';
|
|
2031
|
+
const oauthStatusLabel = allowedOauthStatuses.has(rawOauth) ? rawOauth : 'unknown';
|
|
2032
|
+
const requestsServed = typeof body.requests === 'number' ? body.requests : 0;
|
|
2024
2033
|
console.log('');
|
|
2025
2034
|
console.log(` dario — already running on http://${displayHost}:${port}`);
|
|
2026
2035
|
console.log('');
|
|
2027
|
-
console.log(` OAuth: ${
|
|
2036
|
+
console.log(` OAuth: ${oauthStatusLabel} | requests served: ${requestsServed}`);
|
|
2028
2037
|
console.log('');
|
|
2029
2038
|
console.log(' Usage:');
|
|
2030
2039
|
console.log(` ANTHROPIC_BASE_URL=http://${displayHost}:${port}`);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@askalf/dario",
|
|
3
|
-
"version": "3.38.
|
|
3
|
+
"version": "3.38.1",
|
|
4
4
|
"description": "A local LLM router. One endpoint, every provider — Claude subscriptions, OpenAI, OpenRouter, Groq, local LiteLLM, any OpenAI-compat endpoint — your tools don't need to change.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|