Skip to content

Commit 7c23dab

Browse files
authored
Release v3.8.40
v3.8.40 cycle integration → main. All test gates green (Unit/Integration/Coverage/Node-compat/Quality-Ratchet). The only red check, 'PR Test Policy', is the test-masking heuristic firing on the cumulative ~57-commit release diff (legitimate assert consolidations already reviewed per-PR — Gemini CLI removal #5246, retired GPT models #5280, provider catalog refreshes); overridden with --admin per the documented release-PR convention. CodeQL/SonarQube advisory scans non-blocking; #5278's code already passed CodeQL on main. Homologated on VPS 192.168.0.15 (v3.8.40 healthy).
1 parent 1c18be4 commit 7c23dab

1,007 files changed

Lines changed: 16431 additions & 21323 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.env.example

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -413,7 +413,6 @@ NEXT_PUBLIC_CLOUD_URL=
413413
# debugging or when routing through a corporate mirror. Used by:
414414
# open-sse/services/usage.ts.
415415
#OMNIROUTE_CROF_USAGE_URL=https://crof.ai/usage_api/
416-
#OMNIROUTE_GEMINI_CLI_USAGE_URL=https://cloudcode-pa.googleapis.com/v1internal:loadCodeAssist
417416
#OMNIROUTE_CODEWHISPERER_BASE_URL=https://codewhisperer.us-east-1.amazonaws.com
418417
#OMNIROUTE_OPENCODE_QUOTA_URL=https://opencode.ai/zen/go/v1/quota
419418
#OMNIROUTE_OPENCODE_GO_QUOTA_URL=https://api.z.ai/api/monitor/usage/quota/limit
@@ -721,7 +720,7 @@ CODEX_OAUTH_CLIENT_ID=app_EMoamEEZ73f0CkXaXp7hrann
721720
# Used by: open-sse/executors/theoldllm.ts. Default: 30000 (30s).
722721
# THEOLDLLM_NAV_TIMEOUT_MS=30000
723722

724-
# ── Gemini / Gemini CLI / Antigravity / Windsurf (all Google-based) ──
723+
# ── Gemini / Antigravity / Windsurf (all Google-based) ──
725724
# These providers ship public OAuth client_id/secret values (or Firebase Web
726725
# keys) embedded in their public CLIs/binaries. Defaults are baked into the
727726
# code via open-sse/utils/publicCreds.ts — leave the env vars unset to use
@@ -730,8 +729,6 @@ CODEX_OAUTH_CLIENT_ID=app_EMoamEEZ73f0CkXaXp7hrann
730729
#
731730
# GEMINI_OAUTH_CLIENT_ID=
732731
# GEMINI_OAUTH_CLIENT_SECRET=
733-
# GEMINI_CLI_OAUTH_CLIENT_ID=
734-
# GEMINI_CLI_OAUTH_CLIENT_SECRET=
735732
# ANTIGRAVITY_OAUTH_CLIENT_ID=
736733
# ANTIGRAVITY_OAUTH_CLIENT_SECRET=
737734
# WINDSURF_FIREBASE_API_KEY=
@@ -819,7 +816,7 @@ GITHUB_OAUTH_CLIENT_ID=Iv1.b507a08c87ecfe98
819816
# VISION_BRIDGE_API_KEY=
820817

821818
# ─────────────────────────────────────────────────────────────────────────────
822-
# ⚠️ GOOGLE OAUTH (Antigravity, Gemini CLI) & OTHER PROVIDERS — REMOTE SERVERS
819+
# ⚠️ GOOGLE OAUTH (Antigravity) & OTHER PROVIDERS — REMOTE SERVERS
823820
# ─────────────────────────────────────────────────────────────────────────────
824821
# The default Client IDs above ONLY work when OmniRoute runs on localhost.
825822
# For remote/VPS hosting (including Docker containers on remote servers):
@@ -847,7 +844,7 @@ GITHUB_OAUTH_CLIENT_ID=Iv1.b507a08c87ecfe98
847844
# Used by: open-sse/executors/base.ts — buildHeaders() dynamic lookup.
848845
# Update these when providers release new CLI versions to avoid blocks.
849846

850-
CLAUDE_USER_AGENT="claude-cli/2.1.187 (external, cli)"
847+
CLAUDE_USER_AGENT="claude-cli/2.1.195 (external, cli)"
851848

852849
# Disable the deterministic tool-name cloak applied on both Anthropic-bound paths
853850
# (executors/base.ts native OAuth + executors/cliproxyapi.ts CLIProxyAPI) —
@@ -857,7 +854,7 @@ CLAUDE_USER_AGENT="claude-cli/2.1.187 (external, cli)"
857854
# forward the original names verbatim (debugging only).
858855
# CLAUDE_DISABLE_TOOL_NAME_CLOAK=false
859856
CODEX_USER_AGENT="codex-cli/0.142.0 (Windows 10.0.26200; x64)"
860-
GITHUB_USER_AGENT="GitHubCopilotChat/0.45.1"
857+
GITHUB_USER_AGENT="GitHubCopilotChat/0.54.0"
861858
ANTIGRAVITY_USER_AGENT="antigravity/2.0.1 linux/arm64 google-api-nodejs-client/10.3.0"
862859
KIRO_USER_AGENT="AWS-SDK-JS/3.0.0 kiro-ide/1.0.0"
863860
# KIRO_VERIFY_FULL_CRC=false # opt-in: full per-frame message CRC validation on the Kiro event stream (debug corrupted streams; prelude CRC + TLS already protect framing)
@@ -872,9 +869,8 @@ KIRO_USER_AGENT="AWS-SDK-JS/3.0.0 kiro-ide/1.0.0"
872869
# Used by: open-sse/executors/kiro.ts
873870
# KIRO_VERIFY_FULL_CRC=false
874871
QODER_USER_AGENT="Qoder-Cli"
875-
QWEN_USER_AGENT="QwenCode/0.15.11 (linux; x64)"
872+
QWEN_USER_AGENT="QwenCode/0.19.3 (linux; x64)"
876873
CURSOR_USER_AGENT="Cursor/3.4"
877-
GEMINI_CLI_USER_AGENT="google-api-nodejs-client/10.3.0"
878874

879875
# Override Codex client version sent in headers independently of the
880876
# CODEX_USER_AGENT string. Used by: open-sse/config/codexClient.ts.
@@ -1362,6 +1358,11 @@ APP_LOG_TO_FILE=true
13621358
# Health check result cache TTL (ms). Default: 30000 (30s)
13631359
# PROXY_HEALTH_CACHE_TTL_MS=30000
13641360

1361+
# Unhealthy health check result cache TTL (ms). Default: 2000 (2s)
1362+
# Keeps transient fast-fail timeouts from poisoning a proxy for the full
1363+
# healthy-result cache window under high concurrency.
1364+
# PROXY_HEALTH_UNHEALTHY_CACHE_TTL_MS=2000
1365+
13651366
# Allow OAuth and provider validation flows to bypass a pinned proxy and connect
13661367
# directly when proxy reachability pre-checks fail. Default: false.
13671368
# Also configurable from Dashboard > Settings > Feature Flags.

.github/workflows/docker-publish.yml

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -98,11 +98,13 @@ jobs:
9898
PROMOTE="${PROMOTE_INPUT:-false}"
9999
else
100100
git fetch --tags --quiet || true
101-
HIGHEST=$(git tag -l 'v[0-9]*' | sed 's/^v//' | grep -vE -- '-(rc|alpha|beta|pre|next)' | sort -V | tail -1 || echo "")
102-
if [ -n "$HIGHEST" ] && [ "$VERSION" = "$HIGHEST" ]; then
103-
PROMOTE="true"
104-
else
105-
echo "Version $VERSION is not the highest semver tag (highest=${HIGHEST:-<none>}). Not promoting :latest."
101+
# Decide via the extracted helper, which folds VERSION into the
102+
# candidate set so the result is independent of git-tag sync timing
103+
# on `release` events (#5301). Without that, the freshly-created tag
104+
# is often not yet visible here and :latest stays a release behind.
105+
PROMOTE=$(git tag -l 'v[0-9]*' | bash scripts/ci/should-promote-latest.sh "$VERSION")
106+
if [ "$PROMOTE" != "true" ]; then
107+
echo "Version $VERSION is not the highest stable semver. Not promoting :latest."
106108
fi
107109
fi
108110
echo "promote_latest=$PROMOTE" >> "$GITHUB_OUTPUT"

.github/workflows/wiki-sync.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ name: Wiki Sync
99
# It does NOT overwrite existing wiki pages by default: several docs sources still carry
1010
# stale counts (e.g. ARCHITECTURE.md says "177 providers" while the wiki cover is 226),
1111
# so blind overwrite would regress the wiki. Full content parity (--update-existing) is
12-
# gated on regenerating those sources — see docs/ops/DOCUMENTATION_AUDIT_REPORT.md.
12+
# gated on regenerating those sources first.
1313

1414
on:
1515
push:

.mcp.json.example

Lines changed: 0 additions & 17 deletions
This file was deleted.

@omniroute/opencode-plugin/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,7 @@ Every field is optional. Defaults mirror v0.1.0 behaviour so existing `opencode.
196196
| `combos` | `boolean` | `true` | Discover `/api/combos` and surface them as pseudo-models with LCD capabilities. Combos are keyed under the `combo/<slug>` namespace and labelled `Combo: <name>` in the model picker so they're distinguishable from raw provider/model pairs. |
197197
| `enrichment` | `boolean` | `true` | Pull display names from `/api/pricing/models` AND per-million-token pricing (`input`, `output`, `cached``cacheRead`, `cache_creation``cacheWrite`) from `/api/pricing`, then overlay both onto the live catalog (so the UI shows `Claude 4.7 Opus` with `cost.input: 5`, `cost.output: 25` instead of raw IDs and zeroed cost). |
198198
| `compressionMetadata` | `boolean` | `false` | Pull `/api/context/combos` so combo names get tagged with their compression pipeline, e.g. `Combo: claude-primary [rtk🟡 → caveman🟠]`. Intensity tokens render as traffic-light emoji (🟢 lite/minimal · 🟡 standard · 🟠 aggressive/full · 🔴 ultra) so the picker advertises "how compressed" each combo is at a glance. |
199-
| `providerTag` | `boolean` | `true` | Prepend a short upstream-provider label to the enriched display name with `" - "` separator, so `cc/claude-opus-4-7 → Claude - Claude Opus 4.7` differs visibly from `kr/claude-opus-4-7 → Kiro - Claude Opus 4.7` in the OC TUI model picker. Label resolution: use `/api/pricing/models[<alias>].name` verbatim when ≤8 chars (e.g. `Claude`, `Kiro`, `Codex`, `Qwen`), otherwise fall back to `UPPER(alias)` (e.g. `GitHub Models``GHM`, `Gemini-cli``GEMINI-CLI`). Idempotent. Combos intentionally skipped (the `Combo: ` prefix already conveys multi-upstream). |
199+
| `providerTag` | `boolean` | `true` | Prepend a short upstream-provider label to the enriched display name with `" - "` separator, so `cc/claude-opus-4-7 → Claude - Claude Opus 4.7` differs visibly from `kr/claude-opus-4-7 → Kiro - Claude Opus 4.7` in the OC TUI model picker. Label resolution: use `/api/pricing/models[<alias>].name` verbatim when ≤8 chars (e.g. `Claude`, `Kiro`, `Codex`, `Qwen`), otherwise fall back to `UPPER(alias)` (e.g. `GitHub Models``GHM`, `Gemini``GEMINI`). Idempotent. Combos intentionally skipped (the `Combo: ` prefix already conveys multi-upstream). |
200200
| `usableOnly` | `boolean` | `false` | Read `/api/providers` and filter the catalog to providers that have at least one connection with `isActive: true` AND `testStatus: 'active'`. Subtract-filter semantics: providers unknown to BOTH the pricing-models catalog AND the connection table pass through (so synthetic prefixes like `agentrouter/*` survive). On fetch failure the filter is disabled for the refresh — never hides the whole catalog. |
201201
| `diskCache` | `boolean` | `true` | Persist the last successful `/v1/models` + `/api/combos` + enrichment + connections + compression snapshot to `${OPENCODE_DATA_DIR ?? ~/.local/share/opencode}/plugins/omniroute-<providerId>.json`. On a subsequent cold start where `/v1/models` throws (network down / IP whitelist drop / 5xx) the static block hydrates from the snapshot so OC's model picker survives offline. Soft-fail on read/write — never blocks publishing. |
202202
| `geminiSanitization` | `boolean` | `true` | Strip `$schema`/`$ref`/`additionalProperties` from tool params when the model id matches `gemini` |

@omniroute/opencode-plugin/src/index.ts

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1225,15 +1225,15 @@ export interface OmniRouteEnrichmentEntry {
12251225
cacheWrite?: number;
12261226
};
12271227
/**
1228-
* Provider alias prefix seen in `/v1/models` ids (e.g. `cc`, `gemini-cli`).
1228+
* Provider alias prefix seen in `/v1/models` ids (e.g. `cc`, `gemini`).
12291229
* Populated by `defaultOmniRouteEnrichmentFetcher` from
12301230
* `/api/pricing/models` keys. Drives the `usableOnly` alias↔canonical
12311231
* resolution.
12321232
*/
12331233
providerAlias?: string;
12341234
/**
12351235
* Canonical provider id used by `/api/providers` connections (e.g.
1236-
* `claude`, `gemini-cli`, `kiro`). Populated from the per-provider
1236+
* `claude`, `gemini`, `kiro`). Populated from the per-provider
12371237
* `entry.id` field inside `/api/pricing/models`.
12381238
*/
12391239
providerCanonical?: string;
@@ -2046,7 +2046,7 @@ export function formatCompressionPipeline(pipeline: OmniRouteCompressionStep[]):
20462046
export interface OmniRouteProviderConnection {
20472047
/** Connection UUID. */
20482048
id: string;
2049-
/** Canonical provider id, e.g. `claude`, `gemini-cli`, `kiro`. Matches `entry.id` in `/api/pricing/models`. */
2049+
/** Canonical provider id, e.g. `claude`, `gemini`, `kiro`. Matches `entry.id` in `/api/pricing/models`. */
20502050
provider: string;
20512051
/** Connection auth flavor, e.g. `apikey`, `oauth`, `cookie`. */
20522052
authType?: string;
@@ -2125,7 +2125,7 @@ export const defaultOmniRouteProvidersFetcher: OmniRouteProvidersFetcher = async
21252125
* walk only the namespaced keys to derive the alias↔canonical mapping).
21262126
*
21272127
* Returns:
2128-
* - `aliases`: set of alias prefixes safe to keep (e.g. `cc`, `gemini-cli`).
2128+
* - `aliases`: set of alias prefixes safe to keep (e.g. `cc`, `gemini`).
21292129
* - `canonicals`: set of canonical provider ids (e.g. `claude`, `kiro`).
21302130
*
21312131
* Callers should treat membership in EITHER set as "usable" — raw model
@@ -2174,7 +2174,7 @@ export function usableProviderAliasSet(
21742174
}
21752175
// Always include every usable canonical as an alias too — handles the
21762176
// common case where `/v1/models` ids use the canonical id directly
2177-
// (e.g. `gemini-cli/gemini-1.5-pro`).
2177+
// (e.g. `gemini/gemini-1.5-pro`).
21782178
for (const canonical of usableCanonicals) aliases.add(canonical);
21792179
return { aliases, canonicals: usableCanonicals, knownAliases };
21802180
}
@@ -3174,7 +3174,6 @@ export function sanitizeGeminiToolSchemas(payload: unknown): unknown {
31743174
* `gemini-2.5-flash`, etc.)
31753175
* - `models/gemini-…` (Google Generative AI canonical id form)
31763176
* - `google-vertex/gemini-…` (OpenCode + AI-SDK Vertex routing prefix)
3177-
* - `gemini-cli/…` (real OmniRoute alias surfaced on b35 prod `/v1/models`)
31783177
*
31793178
* Liberal by design: a false positive (cleaning a payload that didn't
31803179
* need cleaning) costs only a structuredClone + one walk; a false negative

@omniroute/opencode-plugin/tests/config-shim.test.ts

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1311,9 +1311,9 @@ test("config: providerTag (default-on) prepends '<provider> - ' to enriched raw-
13111311
"gemini-3-flash",
13121312
{
13131313
name: "Gemini 3 Flash",
1314-
providerAlias: "gemini-cli",
1315-
providerCanonical: "gemini-cli",
1316-
providerDisplayName: "Gemini-cli",
1314+
providerAlias: "gemini",
1315+
providerCanonical: "gemini",
1316+
providerDisplayName: "Gemini",
13171317
},
13181318
],
13191319
])
@@ -1335,10 +1335,7 @@ test("config: providerTag (default-on) prepends '<provider> - ' to enriched raw-
13351335
entry.models["opencode-omniroute/claude-sonnet-4-6"].name,
13361336
"Claude - Claude Sonnet 4.6"
13371337
);
1338-
assert.equal(
1339-
entry.models["opencode-omniroute/gemini-3-flash"].name,
1340-
"Gemini-cli - Gemini 3 Flash"
1341-
);
1338+
assert.equal(entry.models["opencode-omniroute/gemini-3-flash"].name, "Gemini - Gemini 3 Flash");
13421339
// Combos stay untouched — `Combo: ` prefix already conveys multi-upstream.
13431340
assert.equal(entry.models["opencode-omniroute/claude-tier"].name, "Claude Tier");
13441341
});

@omniroute/opencode-plugin/tests/gemini-sanitize.test.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -212,8 +212,8 @@ test("shouldSanitizeForGemini: google-vertex/gemini-1.5-flash → true", () => {
212212
assert.equal(shouldSanitizeForGemini({ model: "google-vertex/gemini-1.5-flash" }), true);
213213
});
214214

215-
test("shouldSanitizeForGemini: gemini-cli/gemini-2.5-pro → true (real OmniRoute alias)", () => {
216-
assert.equal(shouldSanitizeForGemini({ model: "gemini-cli/gemini-2.5-pro" }), true);
215+
test("shouldSanitizeForGemini: gemini/gemini-2.5-pro → true", () => {
216+
assert.equal(shouldSanitizeForGemini({ model: "gemini/gemini-2.5-pro" }), true);
217217
});
218218

219219
test("shouldSanitizeForGemini: claude-sonnet-4 → false", () => {

0 commit comments

Comments
 (0)