Conversation
…ation A classified quota/auth/model/policy error can contain transient wording or HTTP codes in its body and context. Do not turn those durable refusals back into retries by matching their text. Reuse LlmError::is_retryable for typed transient failures, retaining the existing relay-400/parse/transport fallback. Verification: 10 focused tests passed, 0 failed, 13242 not selected. Includes quota HTTP-boundary tests, misleading refusal text, ordinary rate limits, and the actual relay timeout-then-success request loop. TUI all-target/all- feature Clippy with CI warning flags, fmt, diff check, static ratchets passed. Extracted old/new classifier probe with real anyhow context reproduces quota and authorization misclassification before and correct behavior after. Initial broad attempt: 6 passed, 1 failed (relay retry expected 2 calls, saw 1). Narrowed production logic, not the existing test; the final run passes. No existing test changed or removed. This does not implement model replacement.
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
No-Issue: this is a bounded retry-classification repair found during the 0.10.1 Fleet availability investigation, not an implementation of automatic model replacement.
Stacked on #6423 to keep the tested runtime baseline and this two-file change separate. Retarget after that prerequisite lands.
A typed quota/auth/model/policy refusal can contain
429,stream request, ortemporarily unavailablein its message/context. The child retry classifier previously reinterpreted those words as transient even after the HTTP boundary classified the refusal as durable.LlmError::is_retryablefor typed transient errors, including server 500 and network failures without a magic phrase.Retry-Afterbehavior.No role, permissions, provider choice, task replay, or model replacement behavior is added.
Verification
-D warnings -A clippy::uninlined_format_args -A clippy::too_many_arguments -A clippy::unnecessary_map_or.cargo fmt --all -- --check, owned diff check, dead-code and blocking-call ratchets passed.anyhowcontext reproduced quota/authz misclassification before the fix and correct behavior after; typed server 500 also changes from incorrectly fatal to retryable. This probe is not HTTP acceptance; that boundary is covered by the focused tests.The first, broader attempt failed an existing relay test (6 passed, 1 failed, expected two calls, saw one). The production logic was narrowed; the existing test was not changed. No tests were removed, ignored, or weakened.
Remaining work
Explicit operator-approved replacement routes, frozen route eligibility, first-request-only replacement, and original/effective-route receipts remain separate work. This PR does not claim to make unavailable Fleet members usable.