Skip to content

Commit 56fd247

Browse files
committed
[fix] Make async client response hook async for httpx AsyncClient
_log_response must be an async function when used as an event hook with httpx.AsyncClient, otherwise await fails on NoneType. Integration tests: requests_test.py (2/2) and aio/test_requests.py (2/2) pass. Made-with: Cursor
1 parent 565b971 commit 56fd247

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

pyatlan_v9/client/aio/atlan.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ def _get_adapter() -> logging.LoggerAdapter:
9292
VERSION = read_text("pyatlan", "version.txt").strip()
9393

9494

95-
def _log_response(response, *args, **kwargs):
95+
async def _log_response(response, *args, **kwargs):
9696
LOGGER.debug("HTTP Status: %s", response.status_code)
9797
LOGGER.debug("URL: %s", response.request.url)
9898

0 commit comments

Comments
 (0)