Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Upgrading django-cms to 3.1.2 and django to 1.8.3

Im trying to upgrade my django-cms project from django-cms 3.1.0 to 3.1.2 and django 1.7.1 to django 1.8.3, but when I run python manage.py runserver in terminal I get this error:

File "/home/testacc/projects/test/env/local/lib/python2.7/site-packages/cms/utils/setup.py", line 33, in validate_settings
    raise ImproperlyConfigured("django CMS requires django.template.context_processors.request in "
django.core.exceptions.ImproperlyConfigured: django CMS requires django.template.context_processors.request in 'django.template.backends.django.DjangoTemplates' context processors.
like image 201
vegazz Avatar asked Dec 06 '22 21:12

vegazz


1 Answers

In Django 1.8 TEMPLATE_CONTEXT_PROCESSORS deprecated. Use this in your settings.py:

TEMPLATES = [
{
    'BACKEND': 'django.template.backends.django.DjangoTemplates',
    'APP_DIRS': True,
    'OPTIONS': {
        'context_processors':
            (
            'django.contrib.auth.context_processors.auth',
            'django.template.context_processors.debug',
            'django.template.context_processors.i18n',
            'django.template.context_processors.media',
            'django.template.context_processors.static',
            'django.template.context_processors.tz',
            'django.template.context_processors.csrf',
            'django.template.context_processors.request',
            'django.contrib.messages.context_processors.messages',
            'sekizai.context_processors.sekizai',
            'cms.context_processors.cms_settings',
            )
    }
},
]
like image 65
user2111922 Avatar answered Dec 29 '22 23:12

user2111922