Skip to content

Fix OpenAPI codegen for binary stream responses#74

Merged
renardeinside merged 8 commits intomainfrom
feat/studio
Feb 15, 2026
Merged

Fix OpenAPI codegen for binary stream responses#74
renardeinside merged 8 commits intomainfrom
feat/studio

Conversation

@renardeinside
Copy link
Copy Markdown
Collaborator

Summary

  • Fix OpenAPI TypeScript codegen returning res.json() for unknown/binary content types (e.g. application/vnd.apache.arrow.stream, application/vnd.apache.parquet). Previously, vendor-specific binary media types fell through to ResponseContentType::Unknown, which incorrectly called res.json() — failing at runtime on binary data.
  • The generated code now returns the raw Response object ({ data: res }) for unrecognized content types, preserving streaming capability via ReadableStream.
  • Added a dedicated test (test_response_binary_stream_returns_raw_response) verifying the fix with a vendor binary content type.

Test plan

  • New test test_response_binary_stream_returns_raw_response passes
  • Full OpenAPI test suite passes (102 tests)
  • Verify generated client code works end-to-end with a FastAPI streaming endpoint

🤖 Generated with Claude Code

@renardeinside renardeinside merged commit 42d9eb3 into main Feb 15, 2026
3 checks passed
@renardeinside renardeinside deleted the feat/studio branch February 15, 2026 14:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant