D
D
Dauren S2016-10-27 18:40:20
Django
Dauren S, 2016-10-27 18:40:20

Django doesn't recognize Cyrillic?

There is a view.py
It contains the following code

# -*- coding:utf-8 -*-
import logging
logger = logging.getLogger(__name__)

def show_from_cat(request,url):
    arr1=['dudududu',2,3,4,5]
    arr2=['dudffffffududu',2,3,4,5]
    arr3=['привет','как дела']
    logger.debug(arr1)
    logger.debug(arr2)
    logger.debug(arr3)

3 the list is not written to the log, why?
Django 1.9.8 Python 3
Nginx, Ubuntu 14, Gunicorn
Mysql entries in utf8-general-ci.
Logs are written, BUT Cyrillic only if I run through runserver
If I run through runserver, then Cyrillic is displayed in the console and written to the log.
If I run through gunicorn, then the Cyrillic alphabet is not written to the logs, but the Latin alphabet is written

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
Dauren S, 2016-10-28
@dauren101

I decided.
Reinstalled django, configured supervisor
michal.karzynski.pl/blog/2013/06/09/django-nginx-g...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question