Fix locale.Error: unsupported locale setting

Mohammed Hammoud
1 min readApr 27, 2017

Ok, so I’ve just encountered the following error on my newly installed Ubuntu Machine: locale.Error: unsupported locale setting when I was trying create a virtual environment with python-virtualenv. After some googling i found the following solution:

export LANGUAGE=en_US.UTF-8
export LANG=en_US.UTF-8
export LC_ALL=en_US.UTF-8
locale-gen en_US.UTF-8
sudo dpkg-reconfigure locales

Happy hacking…

--

--

Mohammed Hammoud

Digital Designer, Backend and Frontend developer from Sweden with experience in usability.