0
votes

I've seen this issue addressed before in other posts and it was recommended to used the trusted host prefix when installing a python package. That has always worked for me but now, for whatever reason, no longer works. This is the message I get when installing any Python package via Pypi.org. It really doesn't matter what package is involved I get the same error regardless.

I have tried changing the condarc file to turn ssl_verify to false and that does not seem to help and I get the same message. Any ideas?

I'm running the latest version of Python via Anaconda.

Also the curl workaround doesn't appear to work as it simply times out

(base) C:\Users\name>pip install --trusted-host pypi.python.org gpyopt Collecting gpyopt Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLError(1, '[SSL: CERTIFICATE_VERIFY_FAIL ED] certificate verify failed (_ssl.c:777)'),)': /simple/gpyopt/ Retrying (Retry(total=3, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLError(1, '[SSL: CERTIFICATE_VERIFY_FAIL ED] certificate verify failed (_ssl.c:777)'),)': /simple/gpyopt/ Retrying (Retry(total=2, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLError(1, '[SSL: CERTIFICATE_VERIFY_FAIL ED] certificate verify failed (_ssl.c:777)'),)': /simple/gpyopt/ Retrying (Retry(total=1, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLError(1, '[SSL: CERTIFICATE_VERIFY_FAIL ED] certificate verify failed (_ssl.c:777)'),)': /simple/gpyopt/ Retrying (Retry(total=0, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLError(1, '[SSL: CERTIFICATE_VERIFY_FAIL ED] certificate verify failed (_ssl.c:777)'),)': /simple/gpyopt/ Could not fetch URL https://pypi.python.org/simple/gpyopt/: There was a proble m confirming the ssl certificate: HTTPSConnectionPool(host='pypi.org', port=443) : Max retries exceeded with url: /simple/gpyopt/ (Caused by SSLError(SSLError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:777)'),)) - skipping Could not find a version that satisfies the requirement gpyopt (from versions: ) No matching distribution found for gpyopt

2

2 Answers

0
votes

Don't know how i get some broken version from python webiste when type python windows 27 in google

This one has included python 2 + pip and its working without issue

https://www.python.org/ftp/python/2.7.15/python-2.7.15.msi
0
votes

Looks like you are using a VPN, this was the same problem for me when I tried to install a package with Vpn connected.

Steps to solve -

1- Disconnect your VPN

2- Try installing the package again