Skip to content

fix(ai): read the status of a gateway error frame in chat_stream - #7112

Merged
dan-petty merged 1 commit into
mainfrom
fix/6828-stream-error-frame-status
Nov 25, 2026
Merged

dan-petty merged 1 commit into
mainfrom
fix/6828-stream-error-frame-status

Conversation

@dan-petty

Copy link
Copy Markdown
Owner

Catch openai.APIError in _openai_compat_stream so gateway SSE error frames map HTTP status, credentials errors, and spend-limit errors instead of escaping as raw APIError.

Closes #6828

Change: openspec/changes/archive/2026-11-25-6828-stream-error-frame-status/

@dan-petty dan-petty added type/bug Type bug: the code does not do what it must scope/ai AI review pipeline, personas, prompts, LLM client, or RAG labels Nov 25, 2026
@dan-petty
dan-petty marked this pull request as ready for review November 25, 2026 06:50
@dan-petty
dan-petty merged commit 3734bc1 into main Nov 25, 2026
27 checks passed
@dan-petty
dan-petty deleted the fix/6828-stream-error-frame-status branch November 25, 2026 06:50
dan-petty-release Bot added a commit that referenced this pull request Nov 25, 2026
🤖 I have created a release *beep* *boop*
---


##
[0.218.0](v0.217.0...v0.218.0)
(2026-11-25)


### Features

* **gh:** refuse agent writes to repo and org settings routes
([#7102](#7102))
([2beb257](2beb257))


### Bug Fixes

* **ai:** read the status of a gateway error frame in chat_stream
([#7112](#7112))
([3734bc1](3734bc1))
* **security:** judge DS-0002 in harbor pytest Dockerfile
([#7109](#7109))
([ae8bc8b](ae8bc8b))
* **service:** decode job records in webhook issue caching
([#7111](#7111))
([e06d0b4](e06d0b4))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Co-authored-by: dan-petty-release[bot] <346998822+dan-petty-release[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

scope/ai AI review pipeline, personas, prompts, LLM client, or RAG type/bug Type bug: the code does not do what it must

Projects

None yet

Development

Successfully merging this pull request may close these issues.

fix(ai): read the status of a gateway error frame in chat_stream

1 participant