Repository navigation
Description
sudo python setup.py install
ipython
There is a error as flows.
jiangyuping@Lenovo:~/ipython$ ipython
Traceback (most recent call last):
File "/usr/local/bin/ipython", line 4, in
from IPython import start_ipython
File "/home/jiangyuping/ipython/IPython/init.py", line 48, in
from .core.application import Application
File "/home/jiangyuping/ipython/IPython/core/application.py", line 23, in
from traitlets.config.application import Application, catch_config_error
ImportError: No module named traitlets.config.application
Then, pip install ipython
to solve this problem
And, it appears the other error as flows.
jiangyuping@Lenovo:~/ipython$ pip install -e
Traceback (most recent call last):
File "/usr/local/bin/pip", line 9, in
load_entry_point('pip==1.5.6', 'console_scripts', 'pip')()
File "/usr/lib/python2.7/dist-packages/pkg_resources/init.py", line 558, in load_entry_point
return get_distribution(dist).load_entry_point(group, name)
File "/usr/lib/python2.7/dist-packages/pkg_resources/init.py", line 2682, in load_entry_point
return ep.load()
File "/usr/lib/python2.7/dist-packages/pkg_resources/init.py", line 2355, in load
return self.resolve()
File "/usr/lib/python2.7/dist-packages/pkg_resources/init.py", line 2361, in resolve
module = import(self.module_name, fromlist=['name'], level=0)
File "/usr/local/lib/python2.7/dist-packages/pip-1.5.6-py2.7.egg/pip/init.py", line 11, in
from pip.vcs import git, mercurial, subversion, bazaar # noqa
File "/usr/local/lib/python2.7/dist-packages/pip-1.5.6-py2.7.egg/pip/vcs/mercurial.py", line 9, in
from pip.download import path_to_url
File "/usr/local/lib/python2.7/dist-packages/pip-1.5.6-py2.7.egg/pip/download.py", line 22, in
from pip._vendor import requests, six
File "/usr/local/lib/python2.7/dist-packages/pip-1.5.6-py2.7.egg/pip/_vendor/requests/init.py", line 53, in
from .packages.urllib3.contrib import pyopenssl
File "/usr/local/lib/python2.7/dist-packages/pip-1.5.6-py2.7.egg/pip/_vendor/requests/packages/urllib3/contrib/pyopenssl.py", line 70, in
ssl.PROTOCOL_SSLv3: OpenSSL.SSL.SSLv3_METHOD,
AttributeError: 'module' object has no attribute 'PROTOCOL_SSLv3'
Activity
takluyver commentedon Jul 21, 2016
That's not an IPython issue, but you've got your Python into a mess somehow. I'd start by deleting the copy of pip you've got installed as an egg:
Then, guessing that you're on Debian/Ubuntu or something similar, start with pip provided by the distribution, and use that to install a newer version:
And then try installing IPython again:
applar commentedon Jul 21, 2016
@takluyver I do it with your suggestion, but, it doesn't work.
takluyver commentedon Jul 21, 2016
Which bit didn't work? I'm not psychic ;-)
applar commentedon Jul 21, 2016
@takluyver The last one code doesn't work. When running it, it appears that error. However, thank you very much.
takluyver commentedon Jul 21, 2016
Can you paste the error you get? If the earlier commands worked, it can't be exactly the same, because you deleted the file that the error was coming from before.
applar commentedon Jul 22, 2016
@takluyver
jiangyuping@Lenovo:/$ pip install --upgrade --user setuptools pip
Traceback (most recent call last):
File "/usr/local/bin/pip", line 9, in
load_entry_point('pip==1.5.6', 'console_scripts', 'pip')()
File "/usr/lib/python2.7/dist-packages/pkg_resources/init.py", line 558, in load_entry_point
return get_distribution(dist).load_entry_point(group, name)
File "/usr/lib/python2.7/dist-packages/pkg_resources/init.py", line 2682, in load_entry_point
return ep.load()
File "/usr/lib/python2.7/dist-packages/pkg_resources/init.py", line 2355, in load
return self.resolve()
File "/usr/lib/python2.7/dist-packages/pkg_resources/init.py", line 2361, in resolve
module = import(self.module_name, fromlist=['name'], level=0)
File "/usr/local/lib/python2.7/dist-packages/pip-1.5.6-py2.7.egg/pip/init.py", line 11, in
from pip.vcs import git, mercurial, subversion, bazaar # noqa
File "/usr/local/lib/python2.7/dist-packages/pip-1.5.6-py2.7.egg/pip/vcs/mercurial.py", line 9, in
from pip.download import path_to_url
File "/usr/local/lib/python2.7/dist-packages/pip-1.5.6-py2.7.egg/pip/download.py", line 22, in
from pip._vendor import requests, six
File "/usr/local/lib/python2.7/dist-packages/pip-1.5.6-py2.7.egg/pip/_vendor/requests/init.py", line 53, in
from .packages.urllib3.contrib import pyopenssl
File "/usr/local/lib/python2.7/dist-packages/pip-1.5.6-py2.7.egg/pip/_vendor/requests/packages/urllib3/contrib/pyopenssl.py", line 70, in
ssl.PROTOCOL_SSLv3: OpenSSL.SSL.SSLv3_METHOD,
AttributeError: 'module' object has no attribute 'PROTOCOL_SSLv3'
takluyver commentedon Jul 23, 2016
It appears that this command had no effect:
hzcyf commentedon Aug 5, 2017
thanks you !