python pip install出现问题

1、pip install时,还是出现了这个错误:
subprocess.CalledProcessError: Command'('lsb_release', '-a')'returned non-zeroexitstatus

解决方法:
找到lsb_release.py文件,把它们拷贝到报的错误中subprocess.py所在文件夹

命令如下:

sudo find / -name'lsb_release.py'

# result:
/usr/local/python3.6/lsb_release.py
/usr/share/pyshared/lsb_release.py
/usr/lib/python3/dist-packages/lsb_release.py
/usr/lib/python2.7/dist-packages/lsb_release.py


sudo find /usr -name python3.6

# result
/usr/local/python3.6
/usr/local/python3.6/bin/python3.6
/usr/local/python3.6/lib/python3.6


sudo cp /usr/lib/python3/dist-packages/lsb_release.py /usr/local/python3.6/lib/python3.6/

 

posted @ 2019-11-29 15:44  糖醋排骨加辣椒  阅读(1083)  评论(0编辑  收藏  举报