How can I install a specific version of pip via easy-install? - Mac OS Mavericks

不羁岁月 提交于 2019-12-18 09:22:08

问题


I am constantly getting the

Cannot fetch index base URL https://pypi.python.org/simple/

whenever I try to pip install anything with the most recent pip version.

I read on some other questions that pip was having SSL related issues in its latest version and recommended to install pip 1.2.1.

How do I install a specific version of pip via easy_install for example?


回答1:


You should be able to install pip with pip:

pip install --upgrade pip==1.2.1



回答2:


Based on your context, you can uninstall as above and then run:

sudo easy_install pip==1.2.1

No more pesky SSL errors.




回答3:


Uninstall any previous installation of pip. Considering you are using system wide installation,

sudo apt-get remove python-pip

and also,

pip uninstall pip

Now,

sudo apt-get install python-setuptools
sudo easy_install pip==<specific version>
sudo pip install virtualenv

It's preferred to use virtual environment though.



来源:https://stackoverflow.com/questions/25942386/how-can-i-install-a-specific-version-of-pip-via-easy-install-mac-os-mavericks

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!