Class
AsyncHttpxClientWrapper
src/openai/_base_client.py:1463–1472
· src/openai/_base_client.py::AsyncHttpxClientWrapper
Source from the content-addressed store, hash-verified
| 1461 | |
| 1462 | |
| 1463 | class AsyncHttpxClientWrapper(DefaultAsyncHttpxClient): |
| 1464 | def __del__(self) -> None: |
| 1465 | if self.is_closed: |
| 1466 | return |
| 1467 | |
| 1468 | try: |
| 1469 | class="cm"># TODO(someday): support non asyncio runtimes here |
| 1470 | asyncio.get_running_loop().create_task(self.aclose()) |
| 1471 | except Exception: |
| 1472 | pass |
| 1473 | |
| 1474 | |
| 1475 | class AsyncAPIClient(BaseClient[httpx.AsyncClient, AsyncStream[Any]]): |
Tested by
no test coverage detected