[Fixed]-Image don't shown in Django LFS

1👍

Your problem is that media root path contains non-ASCII characters, such as “Рабочий стол”.

Posible solutions:

  • Move your project to ASCII-only (non-Cyrillic in your case) path
  • Use Python3 instead 2, which not have this Unicode problems
  • Change MEDIA_ROOT setting to Unicode string, e.g. u'/home/stp/Рабочий стол/myproject/media/'

0👍

To get image and override ANSII encoding I’ve done following:

  • Added string # -*- coding: utf-8 -*- at the beginning of the
    settings.py in my LFS;
  • As Mr. Tikhonov said, changed MEDIA_ROOT string

After that images started to load normally.

Leave a comment