Offline compression error (django_compressor app) after django update

I just upgrade Django 1.4.2 to 1.5, and I started getting the django_compressor error message .

You have offline compression enabled but key "eb225276268ea55d3b90c71df63109d9" is missing from offline manifest. You may need to run "python manage.py compress".

Also, I updated django_compressor to the latest version (actual 1.2) and still get the same error.

When I try python manage.py compress, I noticed that:

c:\python27\lib\site-packages\django\utils\hashcompat.py:9: DeprecationWarning: django.utils.hashcompat is deprecated; use hashlib instead DeprecationWarning)

Does this notification apply to offline compression error?

[UPDATED] I find one more interesting thing ...

In the template I was having a problem with, I deleted all the css that should be compressed:

 {% extends "base.html" %}
    {%  block head %}
        {% load compress %}
        {% compress css %}

        {% endcompress %}
    {% endblock %}
...

I controlled the python control:

python manage.py compress 
python manage.py collectstatic   --noinput

no mistakes.

But ... The problem is still happening.

You have offline compression enabled but key "e764a8b7e7e314ed8c98aa5d25fc76b4" is missing from offline manifest. You may need to run "python manage.py compress".
1   {% extends "base.html" %}
2   {% block head %}
3   {% load compress %}
4   {% compress css %}
5   
6   {% endcompress %}
7   {% endblock %}
8   

Other important information: the .html file was specified when I ran python manage.py compress

+5
source share
3

, {% load compress %} js css base.html. . , django.

+2

, , , , python manage.py compress, .

- , , , , compress.py( ), , , compress.

{% compress js%} {% compress js%}

{% endcompress%}

{% endcompress%}

, manifest.json.

0

.

, , , .

Basically, if you tell the compressor NOT to try to compress files on every HTTP request (autonomous compression), it will look for the Django cache system to find the path to the compressed version of your assets.

If autonomous compression is turned on and it cannot find the file path, the cache says that it should be there, it does not work.

-2
source

All Articles