Iterate over the content of the response body in chunks. This method should be used for responses received from the `stream` method to process large response bodies without loading them entirely into memory. It allows for efficient processing of potentially large data by yie
(self)
| 46 | """ |
| 47 | |
| 48 | def read_stream(self) -> AsyncIterator[bytes]: |
| 49 | """Iterate over the content of the response body in chunks. |
| 50 | |
| 51 | This method should be used for responses received from the `stream` method to process |
| 52 | large response bodies without loading them entirely into memory. It allows for efficient |
| 53 | processing of potentially large data by yielding chunks sequentially. |
| 54 | |
| 55 | Raises: |
| 56 | RuntimeError: If the stream has already been consumed or if the response was not obtained from the `stream` |
| 57 | method. |
| 58 | """ |
| 59 | |
| 60 | |
| 61 | @dataclass(frozen=True) |
no outgoing calls