Search code examples
pythonpippython-requestsupgradepython-3.7

could not import requests and bs4


I want to import requests library and bs4 in pycharm but I got( no module ) enter image description here

and as i click install package I got error

enter image description here

It recommend to update pip 20 to 21 but when I want to upgrade pip in scripts folder I got invalid syntax error

enter image description here


Solution

  • Based on

    certificate verify failed: certificate not yet valid

    I'm pretty certain that your computer's clock is incorrect. Check that first. If that's not the case, there might be a broken MITM SSL proxy in the way, which we can't do much about.

    As for your problem upgrading Pip, you have a typo. You'll want --upgrade, not -upgrade. However, that's likely to fail too if you can't establish connections to the server hosting Python packages (including Pip).