[PYTHON] [OSX] [pyenv] What to do when an SSL error occurs in pip

If I replace Python with 3.5 and 2.7.10 and try to package it as usual pip._vendor.requests.exceptions.SSLError: unknown error (_ssl.c:3031) I was in trouble. The environment is OSX Yosemite, pyenv for Python version control.

So how to deal with it. First of all, if it is ordinary Python,

Users / (your name) /.pyenv/versions/2.7.10 or 3.5.0/lib/python2.7 or python3.5 / site-packages / pip / download.py

With Anaconda,

Users / (your name) /.pyenv/anaconda-(version name) /lib/python (version name) /site-packages/pip/download.py

Is OK if you modify as follows.

# Dispatch the actual request
return super(PipSession, self).request(method, url, *args, **kwargs)

From

# Dispatch the actual request
return super(PipSession, self).request(method, url, verify=False, *args, **kwargs)

What. This is OK. (Adding verify = False)

[reference] http://qiita.com/_akisato/items/4b531aab65de8cd2909a

Recommended Posts

[OSX] [pyenv] What to do when an SSL error occurs in pip
What to do when an error occurs with import _ssl
What to do when SSL error occurs in pip in Windows10, miniconda, VScode environment
[Python] What to do if an error occurs in pip (pyinstaller, pyautogui, etc.)
[python] What to do when an error occurs in send_keys of headless chrome
[Beanstalk] What to do when an error occurs with import uuid
What to do if you get an Undefined error when trying to use pip with pyenv
[Python] What to do when an error related to SSL authentication is returned
What to do if an error occurs when importing numpy with VScode
What to do if a UnicodeDecodeError occurs in pip
What to do if you get an error when installing python with pyenv
What to do if an SSL connection error (ssl.SSLError: [SSL: DH_KEY_TOO_SMALL]) occurs on Ubuntu 20.04
What to do when a Remove Error occurs when updating conda
What to do if a 0xC0000005 error occurs in tf.train.start_queue_runners ()
What to do when "SSL: CERTIFICATE_VERIFY_FAILED _ssl.c: 1056" appears in Python
[Python] Type Error:'WebElement' object is not iterable What to do when an error occurs
What to do if you get an OpenSSL error when installing Python 2 with pyenv
What to do if you get an error when importing matplotlib in Python (Mac)
What to do when UnicodeDecodeError occurs during read_csv in pandas (pd.read_table ())
What to do when ModuleNotFoundError: No module named'XXX' occurs in Python
What to do if you get an error when running "certbot renew" in CakePHP environment
What to do if pyenv install does not proceed with an error
What to do if you get an error when trying to load mnist
What to do when PermissionError of tempfile.mkstemp occurs
What to do if you get an error when installing Dlib (Ubuntu)
What to do when psycopg2 throws an error when pipenv lock under Pipenv environment
What to do when a warning message is displayed in pip list
[Django] What to do if an Integrity Error occurs when registering data from the management site to the database
[Python] I want to know the variables in the function when an error occurs!
What to do if a Unicode Encode Error occurs in Sublime Text Python
What to do if pip install fails in Xcode 5.1
[openpyxl] What to do when IllegalCharacterError appears in pandas.DataFrame.to_excel
A memorandum when an error occurs with pip install
What to do if you get an error when trying to send a message in tasks.loop () immediately after startup
What to do if the print command itself causes an error in Maya python
What to do if you get "(35,'SSL connect error')" in pycurl (one of them)
What to do if you run python in IntelliJ and end with an error
[AWS] What to do when you want to pip with Lambda
What to do if pip gives a DistributionError in Homebrew
What to do when "Invalid HTTP_HOST header" appears in Django
What to do if a communication error occurs due to proxy when installing with package management of pip, npm, gem
What to do when Ubuntu crashes
What to do when a Missing artifact occurs in a jar that is not defined in pom.xml
I get an error when trying to install maec 4.0.1.0 with pip
What to do when the value type is ambiguous in Python?
What to do if you get an error saying c compiler cannot create executables in configure
What to do if you get a must override `get_config` error when trying to model.save in Keras
I built an environment from centos installation to php source expansion on linux, but what to do when a browser error occurs
[Memorandum] What to do when a warning appears after executing pip list
What to do when the result downloaded via scrapy is in English
What to do when pyinstaller: error: argument --add-binary: invalid add_data_or_binary value: appears
[Docker] What to do when error Couldn't find the binary git appears
What to do if you can't install with pip in babun environment
What to do when the warning "The environment is in consistent ..." appears in the Anaconda environment
[Question] In sk-learn random forest regression, an error occurs when the number of parallels is set to -1.
How to write what to do when an application is first displayed in Qt for Python with Designer
What to do in my case when pyenv install is not possible after upgrading to macOS Big Sur
What to do if you get a "No versions found" error in pipenv
What to do if CERTIFICATE_VERIFY_FAILED occurs when nltk.download () is done on macOS pyhon
What to do if pipreqs results in UnicodeDecodeError
I got an error when trying to run Hello World in Go language