We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 1abbde7 commit f5fc9b0Copy full SHA for f5fc9b0
replicate/helpers.py
@@ -117,7 +117,7 @@ class FileOutput(httpx.SyncByteStream, httpx.AsyncByteStream):
117
url: str
118
client: "Client"
119
120
- def __init__(self, url: str, client: "Client"):
+ def __init__(self, url: str, client: "Client") -> None:
121
self.url = url
122
self.client = client
123
@@ -129,8 +129,7 @@ def read(self) -> bytes:
129
def __iter__(self) -> Iterator[bytes]:
130
with self.client._client.stream("GET", self.url) as response:
131
response.raise_for_status()
132
- for chunk in response.iter_bytes():
133
- yield chunk
+ yield from response.iter_bytes()
134
135
async def aread(self) -> bytes:
136
async with self.client._async_client.stream("GET", self.url) as response:
0 commit comments