Python pip

I encountered a problem when installing pip and using:

pip
Traceback (most recent call last):
File "/usr/bin/pip", line 9, in <module>
 from pip import main
ImportError: cannot import name main

I found a post on the Internet, reinstalled to solve the problem, and reposted it

Original link

I encountered ImportError: cannot import name 'IncompleteRead' error while using pip on ubuntu,

Whether you enter pip, pip3 or pip3.4, it is the same. It is known on the Internet that this is a bug of python pip. I went to the Internet to find a lot of methods. Some people said to use sudo easy_install -U pip. Some domestic pypi mirror sources:

Alibaba Cloud is the fastest http://mirrors.aliyun.com/pypi/simple/University of Science and Technology of China https://pypi.mirrors.ustc.edu.cn/simple/douban http://pypi.douban. com/simple/ Python official https://pypi.python.org/simple/ v2ex http://pypi.v2ex.com/simple/ Chinese Academy of Sciences http://pypi.mirrors.opencas.cn/simple/ Tsinghua University https ://pypi.tuna.tsinghua.edu.cn/simple/

terminal execution

sudo easy_install -U -i http://pypi.douban.com/simple/ pip

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=325224920&siteId=291194637