The problem was postman. I replaced the function: get_user_model()
with User
on the postman/models.py file:
django-compressor: Invalid template
-
01-10-2022 - |
Domanda
I'm using django-compressor for a project, but when I run the ./manage compress
command I got a list of errors like:
Invalid template /home/somepath: 'some_template_tags' is not a valid tag library: ImportError raised loading postman.templatetags.some_template_tags: cannot import name SomeLibrary
I don't have any extra information. Moreover the application is added to INSTALLED_APPS
and the template tags runs normally without django-compressor.
Update:
This is the settings.py
file:
INSTALLED_APPS = (
'django.contrib.staticfiles',
'cms',
'mptt',
'menus',
'south',
'sekizai',
'classytags',
'postman',
# More apps
'compressor',
)
# More lines
STATICFILES_FINDERS = (
'django.contrib.staticfiles.finders.FileSystemFinder',
'django.contrib.staticfiles.finders.AppDirectoriesFinder',
'compressor.finders.CompressorFinder',
)
Soluzione
Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow