You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Bug]: OpenCode ChatGPT usage-limit failures drop the reset time, so auto-resume never arms #26265
I included enough detail to reproduce or investigate the problem.
Area
apps/server
Steps to reproduce
Connect the OpenCode provider (OpenCode 2.x) to a ChatGPT subscription through OpenAI OAuth.
Run a thread on a ChatGPT-backed OpenAI model, such as openai/gpt-6-astra, until the Codex usage window is exhausted.
Look at the failed thread.
Expected behavior
The usage-limit failure carries the reset time ChatGPT reports. The thread shows "Resets …" with the resume-at-reset and snooze actions, and auto-resume arms for that time.
Actual behavior
The thread fails as usage_limit with no resetAt. It shows "Reset time unavailable; retry manually", hides the resume and snooze actions, and never auto-resumes.
Stored failure:
{"class":"usage_limit","message":"The usage limit has been reached","code":"provider.quota","retryable":null}
ChatGPT does report the reset. Its 429 body is:
{"error":{"type":"usage_limit_reached","message":"The usage limit has been reached","plan_type":"plus","resets_at":1788753614,"resets_in_seconds":57361}}
OpenCode 2 forwards this as error.response.body on session.execution.failed, but the OpenCode 2 adapter (packages/provider-opencode/src/server/v2/adapter.ts) only reads type, message, and status.
Activity