Skip to content

Generate typed SSE transport and upgrade reqwest 0.13 - #51

Draft
lightsofapollo wants to merge 3 commits into
mainfrom
fix/issue-50-internal-sse
Draft

Generate typed SSE transport and upgrade reqwest 0.13#51
lightsofapollo wants to merge 3 commits into
mainfrom
fix/issue-50-internal-sse

Conversation

@lightsofapollo

@lightsofapollo lightsofapollo commented Jul 29, 2026

Copy link
Copy Markdown
Contributor

Summary

  • replace generated reqwest-eventsource usage with a conditional standalone sse.rs transport
  • expose raw and typed SseEvent<T> streams while preserving the existing payload-only stream<T> API
  • support SSE id and retry metadata, bounded reconnection, and Last-Event-ID resumption
  • preserve OpenAI [DONE] handling and Anthropic named event lifecycles
  • upgrade generated dependencies to reqwest 0.13, reqwest-middleware 0.5, reqwest-retry 0.9, reqwest-tracing 0.7, and thiserror 2
  • infer reqwest 0.13 and middleware 0.5 serialization/streaming features from the generated code

Why

reqwest-eventsource still depends on reqwest 0.12, which blocked the dependency upgrades tracked in #50. Generating the small SSE transport directly removes that coupling and gives generated clients control over framing, typing, response limits, and reconnection semantics. The generated and generator-owned HTTP stacks now resolve on reqwest 0.13.

Validation

  • cargo test --all-features
  • cargo clippy --lib --bins --all-features -- -D warnings
  • cargo fmt --all -- --check
  • generated dependency-fragment compile tests
  • deterministic chunk-boundary and two-connection Last-Event-ID resume tests
  • live OpenAI- and Anthropic-compatible streaming against http://192.168.68.55:1234
  • packaged-crate install smoke and checked-in server example compilation

Closes #50.

@vercel

vercel Bot commented Jul 29, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
openapi-to-rust Ready Ready Preview, Comment Jul 29, 2026 3:46pm

Request Review

@lightsofapollo lightsofapollo changed the title Generate a standalone typed SSE transport Generate typed SSE transport and upgrade reqwest 0.13 Jul 29, 2026
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.

[feature]: reqwest 0.13

1 participant