mirror of
https://github.com/anomalyco/opencode.git
synced 2026-05-23 12:54:42 +00:00
fix: show helpful message when free usage limit is exceeded (#13005)
This commit is contained in:
parent
1d11a0adfd
commit
8bdf6fa359
1 changed files with 2 additions and 0 deletions
|
|
@ -64,6 +64,8 @@ export namespace SessionRetry {
|
|||
|
||||
if (MessageV2.APIError.isInstance(error)) {
|
||||
if (!error.data.isRetryable) return undefined
|
||||
if (error.data.responseBody?.includes("FreeUsageLimitError"))
|
||||
return `Free usage exceeded, add credits https://opencode.ai/zen`
|
||||
return error.data.message.includes("Overloaded") ? "Provider is overloaded" : error.data.message
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue