Skip to content

Commit

Permalink
fix: missed await at _request aread
Browse files Browse the repository at this point in the history
  • Loading branch information
csgulati09 committed Feb 13, 2024
1 parent bc9758f commit 42032b3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion portkey_ai/api_resources/base_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -674,7 +674,7 @@ async def _request(
except httpx.HTTPStatusError as err: # 4xx and 5xx errors
# If the response is streamed then we need to explicitly read the response
# to completion before attempting to access the response text.
err.response.read()
await err.response.aread()
raise self._make_status_error_from_response(request, err.response) from None
except httpx.TimeoutException as err:
raise APITimeoutError(request=request) from err
Expand Down

0 comments on commit 42032b3

Please sign in to comment.