問題:
Full stacktrace:完整的堆棧跟蹤:
➜ ~ pip install virtualenv
Traceback (most recent call last):
File "/usr/bin/pip", line 11, in <module>
sys.exit(main())
File "/usr/lib/python3.4/site-packages/pip/__init__.py", line 215, in main
locale.setlocale(locale.LC_ALL, '')
File "/usr/lib64/python3.4/locale.py", line 592, in setlocale
return _setlocale(category, locale)
locale.Error: unsupported locale setting
On the same server, I successfully ran pip install virtualenv
with python 2.7.x.在同一臺服務器上,我使用 python 2.7.x 成功運行了pip install virtualenv
。
Now, I've just installed python3.4 using curl https://bootstrap.pypa.io/get-pip.py | python3.4
現在,我剛剛使用curl https://bootstrap.pypa.io/get-pip.py | python3.4
安裝了 python3.4 curl https://bootstrap.pypa.io/get-pip.py | python3.4
curl https://bootstrap.pypa.io/get-pip.py | python3.4
. curl https://bootstrap.pypa.io/get-pip.py | python3.4
。
➜ ~ pip --version
pip 8.1.1 from /usr/lib/python3.4/site-packages (python 3.4)
pip uninstall virtualenv
throws the same error too pip uninstall virtualenv
拋出同樣的錯誤
解決方案:
參考一: https://stackoom.com/question/2Shld參考二: pip install - locale.Error: unsupported locale setting