[CENTOS] What to do if you are told "Import Error: cannot import name'HTTPSHandler'" when building a virtual environment using virtualenv

background

I wanted to build a python environment using virtualenv in my lab, but I got the error ʻImportError: cannot import name'HTTPSHandler'`. As a memorandum.

Execution environment

CentOS 7

procedure

  1. Install openssl-devel with yum install openssl-devel
  2. Remake python

Recommended Posts

What to do if you are told "Import Error: cannot import name'HTTPSHandler'" when building a virtual environment using virtualenv
What to do if you get a memory error when converting from PySparkDataFrame to PandasDataFrame
What to do if you get an Import Error when importing matplotlib with Jupyter
ImportError: No module What to do when you are told
What to do if you get the error ʻERR_FEATURE_UNAVAILABLE_ON_PLATFORM` when using ts-node-dev on Linux
What to do if you get a Cannot retrieve metalink for repository error in yum
What to do if you get an error when running "certbot renew" in CakePHP environment
What to do if you can't create a virtual environment using venv even though you're following the Django official website
What to do if you get a must override `get_config` error when trying to model.save in Keras
What to do if pip --user returns an error in a virtual environment created with pyenv
What to do if you get an error when trying to load mnist
What to do if you get an error when installing Dlib (Ubuntu)
What to do if you get a "Wrong Python Platform" warning when using Python with the NetBeans IDE
What to do if you get a Permission denied (public key) error when trying to pull on Github
[Python] What to do if you get a ModuleNotFoundError when importing pandas using Jupyter Notebook in Anaconda
What to do if you get a "No versions found" error in pipenv
What to do if you get an error when installing python with pyenv
What to do if you get an error when trying to send a message in tasks.loop () immediately after startup
What to do when "cannot import name xxx" [Python]
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 if you don't want to use Japanese column names when using ortoolpy.logistics_network
What to do if you get the error "Error: opencv3: Does not support building both Python 2 and 3 wrappers" when installing openCV 3
What to do if you are addicted to Windows character code
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 an error occurs with import _ssl
What to do if you get Swagger-codegen in python and Import Error: No module named
What to do if you get an Undefined error when trying to use pip with pyenv
What to do if you install openCV3 and make a symbolic link, but when you do "import cv2", "No module named'cv2'" appears
What to do if you get a minus zero in Python
[Beanstalk] What to do when an error occurs with import uuid
What to do if you get a UnicodeDecodeError with pip install
What to do if you get an error like'Qstring' has already been set to version 1 using mne python
Building a virtual environment using homebrew + pyenv-virtualenv
It is good to create an environment with runtime error => venv when using pyplot backends of macosx on a virtual environment created with virtualenv.
If you are told cannot by Python import, review the file name
What to do if you should have set an ssh key but are prompted for a password
What to do if you get a TypeError with numpy min, max
What to do if you can't install with pip in babun environment
What to do when "OS Error: [WinError 126] The specified module cannot be found" appears in import torch
What to do if fprintd requires a password when registering your fingerprint
What to do if a symbolic link error occurs in import cv while trying to install OpenCV in Python
What to do if you get the error Target WSGI script'/var/www/xxx/xxx.wsgi' cannot be loaded as python module
What happens if you do "import A, B as C" in Python?
What to do when psycopg2 throws an error when pipenv lock under Pipenv environment
What to do if you get the error RuntimeError: Python is not installed as a framework when trying to use matplitlib and pylab in Python 3.3
What to do if an error occurs when loading a python project created with poetry into VS Code
What to do if a Unicode Encode Error occurs in Sublime Text Python
What to do if you get "Python not configured." Using PyDev in Eclipse
[Python] What to check when you get a Unicode Decode Error in Django
What to do if a version error occurs in the selenium Chrome driver
What to do when you want to receive files from a Windows client remotely
What to do if you can't pipenv shell
What to do if mod_fcgid cannot resolve UnicodeEncodeError
What to do if pip cannot be installed
What are you using when testing with Python?
What to do if you get a Call with too many input arguments error at DoAndReturn in a golang test
What to do if a communication error occurs due to proxy when installing with package management of pip, npm, gem
What to do if you run python in IntelliJ and end with an error
What to do if you can't pip install mysqlclient