0
  • Pip version:9.0.1
  • Python version:3.6.1
  • Operating system:Win10

Description:

I'm trying to set python libraries up in my corporate laptop but run into SSL error 749 when running pip -install for any library. I have tried several suggestions from other posts but they didn't work. I guess the error code is slightly different.

Can someone guide me how to resolve the SSL issue?

What I've run:

C:\WINDOWS\system32>pip install pandas

Collecting pandas
  Could not fetch URL https://pypi.python.org/simple/pandas/: There was a problem confirming the ssl certificate: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:749) - skipping
  Could not find a version that satisfies the requirement pandas (from versions: )
No matching distribution found for pandas
DavidG
  • 24,279
  • 14
  • 89
  • 82
RyanT
  • 1
  • 1
  • can you try it using pip3? pip3 install pandas – Arjun Singh May 24 '17 at 08:56
  • Possible duplicate of [pip install fails with "connection error: \[SSL: CERTIFICATE\_VERIFY\_FAILED\] certificate verify failed (\_ssl.c:598)"](https://stackoverflow.com/questions/25981703/pip-install-fails-with-connection-error-ssl-certificate-verify-failed-certi) – Yaron May 24 '17 at 09:00
  • nope pip3 same error – RyanT May 24 '17 at 09:13

3 Answers3

0

You have to specify cert with this param.

pip --cert /etc/ssl/certs/FOO_Root_CA.pem install pandas

See: Docs » Reference Guide » pip

If specifying your company's root cert doesn't work maybe the cURL one will work: http://curl.haxx.se/ca/cacert.pem

You must use a PEM file and not a CRT file. If you have a CRT file you will need to convert the file to PEM

Also check: SSL Cert Verification

OR

pip install --trusted-host pypi.python.org pandas

  • i've tried with --trusted-host same ssl error 749 as well. Exact same error returned. – RyanT May 24 '17 at 09:14
  • @RyanT : Try this one : `pip install --index-url=http://pypi.python.org/simple/ --trusted-host pypi.python.org pythonPackage` – Abhishek Priyankar May 24 '17 at 09:21
  • yep tried this as well, it prompts for a 'User for rosydpx1:' and login, i tried entering my credentials and it ended up showing error " could not find a version that satisfies the requirement pythonPackage (from versions: ) No matching distribution found for pythonPackage" – RyanT May 24 '17 at 09:41
  • You are using windows so ,Uninstall everything Python and every other python packages and download and install Anaconda .It comes along with every python package you need.[link]( https://www.continuum.io/downloads) – Abhishek Priyankar May 24 '17 at 10:06
0

This can be a very frustrating experience in a corporate environment when you are trying to get something done.

An alternative you can try as a last resort is:

  • downwload the whl file directly from pypi
  • place in the site-packages folder of the python env you want to use
  • run pip install <name of whl file>

If pip encounters any requirements not met, it will try to get via ssl and you'll get the same error. However you can perform the above for that whl as well.

I did this for matplotlib. I already had numpy and most other requirements, but I had to do similar for kiwisolver and cycler packagers.

You can even install pip this way.

This is a very manual and error prone solution (tedious if dependency list is long) but can help you move forward while your IT guys try to figure things out.

Hope this helps.

-2
yum install -y libxml2 libxml2-devel  libxslt libxslt-devel  libffi-devel  python-devel openssl-devel
pip install pyopenssl
pip install parsel 
pip install twisted
phd
  • 82,685
  • 13
  • 120
  • 165
elesos
  • 21
  • 5