Repository navigation
fix(responses): retry canonical Console upload rejection once #4354
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 3 commits
9cb5339
d1494b0
2526b6c
2c63a5d
b597f5f
67548d9
53702ca
07b47dd
926d412
37fb381
32121b4
9858093
b551b52
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -113,7 +113,8 @@ type AttemptRecoveryKind = | |
| | "rate-limit-429" | ||
| | "anthropic-oauth-429" | ||
| | "image-413" | ||
| | "empty-completion"; | ||
| | "empty-completion" | ||
| | "console-go-upload-retry"; | ||
|
Comment on lines
+116
to
+117
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🗄️ Data Integrity & Integration | 🟡 Minor | ⚡ Quick win Extend
Add the three union members and map entries. Add the corresponding 🤖 Prompt for AI Agents |
||
|
|
||
| interface LogAttempt { | ||
| ordinal: number; | ||
|
|
@@ -307,6 +308,7 @@ const RECOVERY_KIND_KEYS = { | |
| "anthropic-oauth-429": "logs.detail.attempt.recovery.anthropicOauth429", | ||
| "image-413": "logs.detail.attempt.recovery.image413", | ||
| "empty-completion": "logs.detail.attempt.recovery.emptyCompletion", | ||
| "console-go-upload-retry": "logs.detail.attempt.recovery.consoleGoUpload", | ||
| } as const satisfies Record<AttemptRecoveryKind, string>; | ||
|
|
||
| /** Map a metric-unavailable reason to its i18n key. */ | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win
Document the complete Console retry predicate.
src/providers/opencode-zen-rate-limit.tsretries only on HTTP 400 from these exact HTTPS paths:https://opencode.ai/zen/v1/{responses,chat/completions,messages}andhttps://opencode.ai/zen/go/v1/{responses,chat/completions,messages}. The JSON error must containparam: null,type: "invalid_request_error", and one of the two exact Console messages. Ports, credentials, queries, fragments, custom destinations, and lookalike paths do not qualify. Provider row names do not select the destination. Document these conditions so users can configure and diagnose this recovery behavior correctly.🤖 Prompt for AI Agents