mirror of
https://github.com/diegosouzapw/OmniRoute.git
synced 2026-07-31 04:12:10 +03:00
OMNIROUTE_QUOTA_FETCH_MIN_INTERVAL_MS / quotaFetchThrottle.ts documents itself as used by 'the provider quota fetchers' (plural), but only codexQuotaFetcher.ts ever called throttleQuotaFetch(). N accounts on one IP for DeepSeek, Bailian, OpenCode, or Crof still burst simultaneously. Wire throttleQuotaFetch() into fetchDeepseekQuota, fetchBailianQuota (both the primary and China-region retry fetch sites), fetchOpencodeQuota, and fetchCrofUsage, placed after the existing cache short-circuit so cache hits stay unaffected (mirrors the codexQuotaFetcher.ts pattern). PROVIDER_LIMITS_SYNC_SPACING_MS / providerLimits.ts's OAuth vs non-OAuth split is left unchanged — that split is intentional by design and already regression-guarded by tests/unit/provider-limits-oauth-sequential-sync.test.ts. The generic usage.ts::getUsageForProvider dispatch path (github, glm, minimax, nanogpt, xai, etc.) is intentionally out of scope for this fix to avoid scope creep; ENVIRONMENT.md now documents the actual post-fix coverage instead of the prior overclaim.