-
-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Closed
Description
Long story short
Aiohttp failing to get response on awaited urls
allUrls = await getAllUrls(a, b, c);
urls = ['url1', 'url3'];
result = await fetchAll(session, tasks, urls);
return json(result);
When using awaited allUrls
I am getting the following error
aiohttp.client_exceptions.ContentTypeError: 0, message='Attempt to decode JSON with unexpected mimetype: '
When I hardcode the urls (by printing them previously) in the variable urls
, it gives the expected output
Expected behaviour
It should be same in both cases. I am dynamically generating the urls and I might be missing something really basic.