diff --git a/changelog.d/fixes/11592-token-health-retry-budget-boundary.md b/changelog.d/fixes/11592-token-health-retry-budget-boundary.md new file mode 100644 index 0000000000..44e2c05337 --- /dev/null +++ b/changelog.d/fixes/11592-token-health-retry-budget-boundary.md @@ -0,0 +1 @@ +- **resilience:** restore the expired-connection retry-budget probe in the token-health sweep — the `!isGitHubAccessTokenOnlyConnection` carve-out reintroduced by #11608 contradicted the boundary pinned by #11592, so a GitHub connection parked at `expired` with retry budget remaining was never probed and could never self-heal ([#11592](https://github.com/diegosouzapw/OmniRoute/pull/11592)). diff --git a/src/lib/tokenHealthCheck.ts b/src/lib/tokenHealthCheck.ts index 432b57d088..b3a4e2e074 100644 --- a/src/lib/tokenHealthCheck.ts +++ b/src/lib/tokenHealthCheck.ts @@ -599,13 +599,6 @@ export async function checkConnection(conn) { const isRecoverableExpiredWithRetryBudget = conn.testStatus === "expired" && conn.lastErrorType !== "account_deactivated" && - // GitHub access-token-only connections have their own dedicated exemption - // (isRecoverableGithubCopilotNoRefresh above): ONLY the exact - // "no_refresh_token" shape self-heals. An "expired" GitHub connection for a - // different reason (e.g. invalid_grant) is genuinely terminal and must stay - // skipped, otherwise the generic retry-budget exemption below reopens #8182's - // wasted-probe fix for every "expired" GitHub connection. - !isGitHubAccessTokenOnlyConnection(conn) && getExpiredRetryCount(conn) < EXPIRED_RETRY_MAX; const terminalStatuses = new Set(["credits_exhausted", "banned", "expired"]); if (