Skip to content

Commit

Permalink
[Change] client: outputs the body when request, continues when large …
Browse files Browse the repository at this point in the history
…body
  • Loading branch information
sebastien committed Sep 30, 2024
1 parent d7f2ad7 commit f0b14d3
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/py/extra/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -436,14 +436,16 @@ async def OnRequest(
status = atom
elif isinstance(atom, HTTPResponse):
res = atom
yield atom.body
break
else:
yield atom
iteration += 1
if (
status is HTTPProcessingStatus.Processing,
streaming is True
or res
and res.headers.contentType in {"text/event-stream"}
and res.headers.contentType in {"text/event-stream"},
):
# TODO: We should swap out the body for a streaming body
cxn.isStreaming = True
Expand Down

0 comments on commit f0b14d3

Please sign in to comment.