Skip to content
Advertisement

Error whenever I run code that requires aiohttp library

Whenever I run code which requires aiohttp, I get the error below:

JavaScript

Examples of codes I’ve tried to run from https://docs.aiohttp.org/en/stable/ include:

JavaScript

and

JavaScript

I’ve tried several other examples but they all produce the same error. What could be causing this?. I’m using python 3.8.6 and the latest version of aiohttp

Update: It seems the error is caused by importing aiohttp. I get the error just by typing ‘import aiohttp’ on cmd.

Advertisement

Answer

It seems that pip install aiohttp installs a version incompatible with my current python version. pip install aiohttp==3.5.4 solved the issue for me. Thank you @edoput for pointing that out.

User contributions licensed under: CC BY-SA
4 People found this is helpful
Advertisement