SSL Error causes Python package install to fail


I’m having a problem this morning installing a package that has worked previously. I think the problem may be at the package supplier end but all suggestions very welcome.

ERROR: Could not install packages due to an EnvironmentError: HTTPSConnectionPool(host='', port=443): Max retries exceeded with url: /packages/bd/c3/5c030d96701c80c9c092c6082f959afc712c4256cc1c95267c56ef9d30e2/canopen-1.2.1-py3-none-any.whl (Caused by SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: certificate is not yet valid (_ssl.c:1123)')))



Actually it does seem to work ok when I create a new venv and pip install canopen there. Maybe it is due to the version of pip the plugin is using. I tried updating the one in the wsl container but that doesn’t seem to be what the plugin is using.

I also get this warning from the build process:

WARNING: You are using pip version 20.3.3; however, version 21.0.1 is available.
You should consider upgrading via the '/usr/bin/python3 -m pip install --upgrade pip' command.

Which is strange as checking the dockerfile it looks like pip should get upgraded as the container is built unless I am mistaken?

RUN pip3 install --upgrade pip
RUN pip3 install debugpy

Hey @edwaugh!

Just for debugging purposes, can you go inside the container and upgrading pip just like instructed just to see if it makes any difference?

If this is the issue, we can try to deal with this on the Dockerfile then.

Hi all,

This is fixed this morning, I think what happened is:

  1. @gauravks recommended deleting all the containers and images through the docker UI and running docker system prune to remove any cache
  2. I then needed to restart (which I only figured out this morning)
  3. The whole container was then rebuilt properly from scratch which caused it to get the latest version of PIP 21.0.1
  4. This resolved the SSL certificate problem when fetching canopen

@gustavo.tx would it be possible for you to check for me if there is an easy way to remove all the docker caches? This would be a good feature of the extension, so I can do a ‘clean build’ when I need to.