I was setting up the python.org website code, built on Django, on my local machine I encountered the error ValueError: unknown locale: UTF-8 while running the ./manage.py migrate command. See screenshot below:

To fix this, I had to set the following environment variables:
export LC_ALL=en_US.UTF-8
export LANG=en_US.UTF-8
There, back to code.
Leave a comment