[Django]-UnicodeEncodeError raised when 'createsuperuser' is called

11👍

This may be caused by the fact that encoding used for the stdin does not support the characters being typed in at the input() prompt.

You can try explicitly setting the encoding to UTF-8 using the PYTHONIOENCODING environment variable before you run the createsuperuser command:

export PYTHONIOENCODING="UTF-8"; python3.6 manage.py createsuperuser

1👍

I think it is the same problem as here:
previous post
You have to add

# -*- coding: utf-8 -*-

in the start of each file to include the right encoding

Leave a comment