I am trying to install the Tornado Python package with pip, but I get this error. I have tried upgrading Python from 2.7.7 to 2.7.14 but I still get the error. I have tried pip install --upgrade pip as well.
Is pip using the wrong version of Python?
lx@LX ~ $ python -V
Python 2.7.14
lx@LX ~ $ pip -V
pip 1.5.4 from /usr/lib/python2.7/dist-packages (python 2.7)
lx@LX ~ $ pip install tornado
Downloading/unpacking tornado
Downloading tornado-5.0.1.tar.gz (504kB): 504kB downloaded
Running setup.py (path:/tmp/pip_build_lx/tornado/setup.py) egg_info for package tornado
Traceback (most recent call last):
File "<string>", line 17, in <module>
File "/tmp/pip_build_lx/tornado/setup.py", line 146, in <module>
raise ImportError("Tornado requires an up-to-date SSL module. This means "
ImportError: Tornado requires an up-to-date SSL module. This means Python 2.7.9+ or 3.4+ (although some distributions have backported the necessary changes to older versions).
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File "<string>", line 17, in <module>
File "/tmp/pip_build_lx/tornado/setup.py", line 146, in <module>
raise ImportError("Tornado requires an up-to-date SSL module. This means "
ImportError: Tornado requires an up-to-date SSL module. This means Python 2.7.9+ or 3.4+ (although some distributions have backported the necessary changes to older versions).
----------------------------------------
Cleaning up...
Command python setup.py egg_info failed with error code 1 in /tmp/pip_build_lx/tornado
Storing debug log for failure in /home/lx/.pip/pip.log
Python version
lx@LX ~ $ python
Python 2.7.14 (default, Mar 19 2018, 20:12:34)
[GCC 4.8.4] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import ssl
>>> ssl
<module 'ssl' from '/usr/local/lib/python2.7/ssl.pyc'>
>>> quit()
lx@LX ~ $