mirror of
https://github.com/zed-industries/zed.git
synced 2026-11-19 23:20:18 +01:00
ee3b5558c5
OpenAI's Codex endpoint reports an exhausted ChatGPT subscription with HTTP 429 and `error.type = "usage_limit_reached"`, but no `error.code`. The Responses parser discarded the type and classified the response from its status alone, making it appear to be transient request throttling. This preserves `error.type` in both Responses and Chat Completions parsing, considers both OpenAI discriminator fields during classification, and falls back from the more-specific `error.code` to `error.type` when populating the existing provider rejection code. Usage-limit errors retain OpenAI's message and are not retried as transient 429s. The regression coverage exercises initial HTTP failures, Responses stream errors, Chat Completions stream errors, unknown OpenAI-compatible provider types, and precedence when both code and type are present. Release Notes: - Fixed ChatGPT subscription usage limits being shown as temporary OpenAI request throttling.