A
A
Alexander2017-07-02 18:27:47
Django
Alexander, 2017-07-02 18:27:47

After running django-admin makemessages I get an Unknown encoding "utf8" error?

I run the command: django-admin.py makemessages
Error:

....
./services/web/migrations/0025_auto_20170701_1737.py
./services/web/migrations/0026_auto_20170701_1819.py
./services/web/migrations/__init__.py
./services/web/models.py
./services/web/tests.py
./services/web/urls.py
./services/web/views.py
xgettext: ./env/lib/python3.6/site-packages/easy_thumbnails/migrations/0002_thumbnaildimensions.py:1: Unknown encoding "utf8". Proceeding with ASCII instead.
xgettext: ./env/lib/python3.6/site-packages/pip/_vendor/webencodings/__init__.py:1: Unknown encoding "utf8". Proceeding with ASCII instead.
xgettext: Non-ASCII string at ./env/lib/python3.6/site-packages/pip/_vendor/webencodings/__init__.py:64.
          Please specify the source encoding through --from-code or through a comment
          as specified in http://www.python.org/peps/pep-0263.html.

I tried to specify in one file at the beginning of the file: # -*- encoding: utf-8 -*-
How can this be fixed?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
A
Astrohas, 2017-07-02
@Astrohas

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

S
sim3x, 2017-07-02
@sim3x

0. Clone turnip. Remove a character from a string. Install fixed version
https://github.com/gsnedders/python-webencodings/b...
1. Add directory to ignore https://stackoverflow.com/questions/7574303/django...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question