Skip to content
This repository was archived by the owner on Mar 26, 2026. It is now read-only.

fix: streaming for sync REST API calls#2204

Merged
parthea merged 2 commits into
mainfrom
fix-sync-streaming
Oct 9, 2024
Merged

fix: streaming for sync REST API calls#2204
parthea merged 2 commits into
mainfrom
fix-sync-streaming

Conversation

@ohmayr

@ohmayr ohmayr commented Oct 7, 2024

Copy link
Copy Markdown
Contributor

Fixes #2076, b/316040436 🦕

Setting stream='True is needed for requests library to avoid loading the entire response into memory.
See: https://requests.readthedocs.io/en/latest/api/#requests.Session.stream

This PR also fixes a bug where _get_response helper for mixin methods appeared to be a synchronous method.

@product-auto-label product-auto-label Bot added the size: s Pull request size is small. label Oct 7, 2024
@ohmayr ohmayr marked this pull request as ready for review October 7, 2024 21:13
@ohmayr ohmayr requested a review from a team October 7, 2024 21:13
@ohmayr ohmayr assigned parthea and unassigned vchudnov-g Oct 7, 2024
@ohmayr ohmayr force-pushed the fix-sync-streaming branch from 840a4d7 to 26439cd Compare October 9, 2024 18:38
@parthea parthea merged commit ce3b84c into main Oct 9, 2024
@parthea parthea deleted the fix-sync-streaming branch October 9, 2024 18:43
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

size: s Pull request size is small.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Streaming over rest doesn't actually stream.

3 participants