OpenCode Go 403 'subscription required' and Z.ai 1313 are retried as transient
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 72/100
- Issue type
- Bug
- Clarity
- Clearly specified
- Activity status
- Active
- Tech stack
- typescript
- Domain
- backend
Research direction
Start with isRetryableAssistantError and NON_RETRYABLE_PROVIDER_ERROR_PATTERN in packages/ai/src/utils/retry.ts, then SUBSCRIPTION_LIMIT_PATTERN and usageLimitScope in retry-fallback/usage-limit.ts. Add the five listed markers to both, keeping the 429 and 503 throttle texts retryable. Done when the five refusals return retryable=false with a scope and the two control texts still return true, checked by the retry tests.
Written by the indexing model from the issue text.
Description
What happened?
Two entitlement or account-state refusals are classified as transient, so the turn retries them with backoff before any fallback. Waiting cannot lift either one:
- 403
An active OpenCode Go subscription is required to use Go models.The body hastype: "server_error", which is what matches the retryableserver.?errorpattern. - Z.ai 429 code 1313
Your request frequency has been limited due to abnormal usage. To restore access, please submit a request.The429matches the retryable pattern.
Observed on one install: the OpenCode Go refusal produced 4 bursts of 3 to 4 retries within 8 to 19 s on 2026-10-13. The 1313 text asks the user to submit a request to restore access, so repeated retries cannot help.
Three similar refusals are already terminal for the retry loop, but no scope is recorded for any of the five (usageLimitScope returns undefined), so the provider only gets the default selector cooldown (20 s, 30 s, or 5 min) and is picked again:
- Kimi 403
Your current subscription does not have access to Kimi Code right now. - Antigravity 400
FAILED_PRECONDITIONUser location is not supported for the API use. - Antigravity 403
Verify your account to continue
Steps to reproduce
On main (b8c1d3a84), isRetryableAssistantError({ stopReason: "error", errorMessage }) from packages/ai/src/utils/retry.ts:
403: {"type":"server_error","message":"Upstream request failed: An active OpenCode Go subscription is required to use Go models."} -> true
429: {"code":"1313","message":"Your request frequency has been limited due to abnormal usage. To restore access, please submit a request."} -> true
The Kimi and Antigravity texts return false. Real throttles (429 Rate limit reached for requests, 503 Our servers are currently overloaded) return true and must stay that way.
Expected behavior
All five are terminal for the retry loop (immediate fallback, no same-model retry) and bind the account. Proposed change: add the markers to NON_RETRYABLE_PROVIDER_ERROR_PATTERN in retry.ts, where non-retryable outranks retryable:
"an active [^\\n]{0,40}subscription is required",
"subscription does not have access",
"user location is not supported",
"request frequency has been limited",
"verify your account to continue",
and the same five to SUBSCRIPTION_LIMIT_PATTERN in retry-fallback/usage-limit.ts, so usageLimitScope is set (account; model for the OpenCode Go text, which contains "models").
On copies of main's two files all five return retryable=false with a scope, and the two control texts stay true.
Version
2026.10.13; the classifier is unchanged on main.
Disclosure: drafted with an AI coding agent from my own session logs; I ran the checks quoted above.
- Dominant language
- TypeScript
- Stars
- 479
- Forks
- 139
- Avg merge
- 6h 56m
- Merged PRs (30d)
- 781
Getting set up
Starts the project's dev container in your browser, under your own GitHub account.
- No Dockerfile or Docker Compose file
- No pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from code-yeongyu/senpi
-
Difficulty 1/5 Under an hour Newbie friendliness 88/100
code-yeongyu/senpi#3475 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
code-yeongyu/senpi#3406 ·
Maintainers usually reply within 1 day
-
Windows: main-screen mouse tracking requires WT_SESSION, so it never enables inside herdr panesOpen
Difficulty 1/5 Under an hour Newbie friendliness 66/100
code-yeongyu/senpi#3353 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
code-yeongyu/senpi#3349 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
code-yeongyu/senpi#3348 ·
Maintainers usually reply within 1 day
All issues in code-yeongyu/senpi
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 67/100
agilepathway/label-checker#739 · 4 comments ·
Maintainers usually reply within 1 day
-
Difficulty 1/5 Under an hour Newbie friendliness 68/100
CopilotKit/OpenBot#800 ·
Maintainers usually reply within 1 day
-
Endpoint links in the tag operations list are below the 24px target sizePossibly taken @AdzerKI claimed this today. Open
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 79/100
ehmpathy/rhachet-roles-bhuild#471 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 73/100
Maintainers usually reply within 1 day