Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save agusmakmun/bbb1351a85d75521c62b8ed3c4406a17 to your computer and use it in GitHub Desktop.
Save agusmakmun/bbb1351a85d75521c62b8ed3c4406a17 to your computer and use it in GitHub Desktop.
user@dev:~$ sudo pip install virtualenv
Traceback (most recent call last):
  File "/usr/local/bin/pip", line 11, in <module>
    sys.exit(main())
  File "/usr/local/lib/python2.7/dist-packages/pip/__init__.py", line 215, in main
    locale.setlocale(locale.LC_ALL, '')
  File "/usr/lib/python2.7/locale.py", line 579, in setlocale
    return _setlocale(category, locale)
locale.Error: unsupported locale setting
user@dev:~$ sudo su
root@dev:/home/user# export LC_ALL="en_US.UTF-8"
root@dev:/home/user# export LC_CTYPE="en_US.UTF-8"
root@dev:/home/user# pip install virtualenv
Collecting virtualenv
  Downloading virtualenv-15.0.1-py2.py3-none-any.whl (1.8MB)
    100% |████████████████████████████████| 1.8MB 533kB/s 
Installing collected packages: virtualenv
Successfully installed virtualenv-15.0.1
@gnulnx
Copy link

gnulnx commented Mar 24, 2018

why though? Everyone say's how to fix it.. I've used Python/pip for a decade and only today on a production system that has worked fine is this error showing up? Any thoughts on WHY it just randomly happened?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment