When I upload some files with non-latin names I got error:
UnicodeEncodeError at /profiles/
'ascii' codec can't encode characters in position 39-41: ordinal not in range(128)
I've tried change supervisor environment how it's described here, but it didn't help. I've added this line in /etc/supervisor/supervisord.conf:
[supervisord]
environment=LANG="ru_RU.utf8", LC_LANG="ru_RU.UTF-8", LC_ALL="ru_RU.UTF-8"
logfile=/var/log/supervisor/supervisord.log ; (main log file;default $CWD/supervisord.log)
pidfile=/var/run/supervisord.pid ; (supervisord pidfile;default supervisord.pid)
childlogdir=/var/log/supervisor ; ('AUTO' child log dir, default $TEMP)
When I put this line in program specific conf file it did not begin working too.
I've tried figure out my encoding, so I've add to template context this variable:
context['locale'] = sys.getfilesystemencoding()
and in template it shows "ANSI_X3.4-1968"
Could please someone explain why changing environment did not solve the problem?
Make sure you have completely restarted supervisord, as described here. Hope it helps!
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With