Problem description
Since the aiohttp is used, the documentation erroneously refers to the urllib3 and synchronous request execution, like here.
Details
ApiClient.call_api() wrong description
The following is written:
Makes the HTTP request (synchronous) and returns deserialized data.
To make an async_req request, set the async_req parameter.
Although the call_api is a synchronous function by itself, the returned value is a __call_api() awaitable, so the request execution is actually asynchronous (using aiohttp in the following steps).
BTW I'm not sure that the async_req parameter (and corresponding request pooling inside the multiprocessing pool) is necessary yet.
_preload_content parameter wrong description
Actually, the _preload_content=False leads to returning the aiohttp.ClientResponse instead of the urllib3.HTTPResponse as wrongly referred by the documentation in many places, and messes up the reader who is going to create the result streaming or something like this.
BTW it's useful to create some parameter or interface to have the (asynchronous) iterateable structured output instead of lists.
Problem description
Since the aiohttp is used, the documentation erroneously refers to the urllib3 and synchronous request execution, like here.
Details
ApiClient.call_api() wrong description
The following is written:
Although the
call_apiis a synchronous function by itself, the returned value is a__call_api()awaitable, so the request execution is actually asynchronous (using aiohttp in the following steps).BTW I'm not sure that the
async_reqparameter (and corresponding request pooling inside the multiprocessing pool) is necessary yet._preload_contentparameter wrong descriptionActually, the
_preload_content=Falseleads to returning theaiohttp.ClientResponseinstead of theurllib3.HTTPResponseas wrongly referred by the documentation in many places, and messes up the reader who is going to create the result streaming or something like this.BTW it's useful to create some parameter or interface to have the (asynchronous) iterateable structured output instead of lists.