Skip to content

feat: sync generated types with schemas v0.10.0 - #85

Merged
edenreich merged 2 commits into
mainfrom
schemas-sync
Jul 21, 2026
Merged

edenreich merged 2 commits into
mainfrom
schemas-sync

Conversation

@inference-gateway-maintainer

Copy link
Copy Markdown
Contributor

Deterministic type sync from inference-gateway/schemas at v0.10.0.

Regenerated with task oas-sync SCHEMAS_REF=refs/tags/v0.10.0 by the org schemas-sync reusable workflow. Re-runs update this PR in place; it closes automatically if the repo is back in sync.

If the new types need follow-up implementation (client surface, examples, docs), comment @claude or @infer on this PR with instructions.

@edenreich

Copy link
Copy Markdown
Contributor

@claude CI is failing, we have schema changes, from the upstream, can you ensure they are all implemented? use /ponytail:ponytail

@inference-gateway-maintainer

inference-gateway-maintainer Bot commented Jul 21, 2026 •

Copy link
Copy Markdown
Contributor Author

Claude finished @edenreich's task in 4m 29s —— View job


Synced schemas v0.10.0 follow-up - done, CI green ✅

  • Gather context
  • Check CI failure logs
  • Implement the schema change in the client
  • Update tests
  • Commit fix (0f31c73)
  • CI passing (run)

What was failing

Schemas v0.10.0 closed SSEvent.event to the seven chat-stream literals (message-start ... stream-end). But create_response_stream was wrapping Responses-API frames in SSEvent with event names like response.created, which now fail Pydantic validation - hence test_create_response_stream failing in CI.

What changed

Per the upstream spec, /responses stream payloads are modeled by ResponseStreamEvent (the event kind lives in its required type field), while SSEvent is chat-only. So:

  • inference_gateway/client.py: added _process_responses_stream, which parses each data: frame directly into a validated ResponseStreamEvent (skipping [DONE]). create_response_stream now yields ResponseStreamEvent instead of SSEvent - callers get typed chunk.type / chunk.delta, no more manual json.loads. Chat streaming (_process_stream_response) is untouched.
  • tests/test_client.py: updated test_create_response_stream to assert on type / sequence_number / delta.

Note: this is a behavior change for create_response_stream callers - previously they got SSEvent and parsed data themselves. ResponseStreamEvent was already exported from __init__.py, and no examples or README sections use the responses stream, so nothing else needed updating.
| Branch

@edenreich
edenreich merged commit 8f397d3 into main Jul 21, 2026
1 check passed
@edenreich
edenreich deleted the schemas-sync branch July 21, 2026 13:24
inference-gateway-releaser Bot added a commit that referenced this pull request Jul 21, 2026
## [0.10.0](v0.9.0...v0.10.0) (2026-07-21)

### ✨ Features

* sync generated types with schemas v0.10.0 ([#85](#85)) ([8f397d3](8f397d3))

### 👷 CI

* add deterministic schemas type sync ([#84](#84)) ([ad894d1](ad894d1))
@inference-gateway-releaser

Copy link
Copy Markdown
Contributor

🎉 This PR is included in version 0.10.0 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

@inference-gateway-releaser inference-gateway-releaser Bot added the released Shipped in a release label Jul 21, 2026
@edenreich edenreich moved this from QA to Done in 2026 Jul 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bot Opened by an org automation released Shipped in a release schema sync

Projects

No open projects
Status: Done

Development

Successfully merging this pull request may close these issues.

1 participant