Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
209 views
in Technique[技术] by (71.8m points)

macos - When installing ROS No module named 'pip._vendor.cachecontrol'

I am following the instructions for intsalling ROS on OSX. When I enter the command pip --version I get the following error. Here's the manual I am following.

Traceback (most recent call last):
  File "/usr/local/bin/pip", line 9, in <module>
    load_entry_point('pip==6.1.1', 'console_scripts', 'pip')()
  File "build/bdist.macosx-10.9-x86_64/egg/pkg_resources/__init__.py", line 552, in load_entry_point
  File "build/bdist.macosx-10.9-x86_64/egg/pkg_resources/__init__.py", line 2672, in load_entry_point
  File "build/bdist.macosx-10.9-x86_64/egg/pkg_resources/__init__.py", line 2345, in load
  File "build/bdist.macosx-10.9-x86_64/egg/pkg_resources/__init__.py", line 2351, in resolve
  File "/usr/local/lib/python2.7/site-packages/pip-6.1.1-py2.7.egg/pip/__init__.py", line 15, in <module>
    from pip.vcs import git, mercurial, subversion, bazaar  # noqa
  File "/usr/local/lib/python2.7/site-packages/pip-6.1.1-py2.7.egg/pip/vcs/mercurial.py", line 10, in <module>
    from pip.download import path_to_url
  File "/usr/local/lib/python2.7/site-packages/pip-6.1.1-py2.7.egg/pip/download.py", line 38, in <module>
    from pip._vendor.cachecontrol import CacheControlAdapter
  File "/usr/local/lib/python2.7/site-packages/pip-6.1.1-py2.7.egg/pip/_vendor/__init__.py", line 92, in load_module
    raise ImportError("No module named '%s'" % (name,))
ImportError: No module named 'pip._vendor.cachecontrol'

You know how can I fix this?

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

I had to do the following to get it work:

  1. brew install openssl
  2. brew unlink python
  3. brew install python
  4. sudo easy_install pip

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...