def validate_templates_configuration():
 for template_engine in django.conf.settings.TEMPLATES:
  backend = template_engine[u'BACKEND']
  if (u'DjangoTemplates' in backend):
   raise ImproperlyConfigured(u'The DjangoTemplates engine was encountered in your template configuration before Django-Jinja. This configuration will not work correctly with Shuup.')
  if (backend == u'django_jinja.backend.Jinja2'):
   if (not template_engine.get(u'APP_DIRS')):
    raise ImproperlyConfigured(u'You have the django_jinja backend configured, but it is not configured to take application template directories into account. Set APP_DIRS = True.')
   options = (template_engine.get(u'OPTIONS') or {})
   if (options.get(u'match_extension') != u'.jinja'):
    raise ImproperlyConfigured(u'You have the django_jinja backend configured, but it is not configured to render `.jinja` templates. Set OPTIONS.match_extension to ".jinja".')
   return True
 raise ImproperlyConfigured(u'The `django_jinja` template backend was not encountered in your TEMPLATES configuration. See the Shuup or Django-Jinja documentation on more information how to configure things correctly.')

def validate_templates_configuration ( ) : for template_engine in django . conf . settings . TEMPLATES : backend = template_engine [ u'BACKEND' ] if ( u'DjangoTemplates' in backend ) : raise ImproperlyConfigured ( u'The DjangoTemplates engine was encountered in your template configuration before Django-Jinja. This configuration will not work correctly with Shuup.' ) if ( backend == u'django_jinja.backend.Jinja2' ) : if ( not template_engine . get ( u'APP_DIRS' ) ) : raise ImproperlyConfigured ( u'You have the django_jinja backend configured, but it is not configured to take application template directories into account. Set APP_DIRS = True.' ) options = ( template_engine . get ( u'OPTIONS' ) or { } ) if ( options . get ( u'match_extension' ) != u'.jinja' ) : raise ImproperlyConfigured ( u'You have the django_jinja backend configured, but it is not configured to render `.jinja` templates. Set OPTIONS.match_extension to ".jinja".' ) return True raise ImproperlyConfigured ( u'The `django_jinja` template backend was not encountered in your TEMPLATES configuration. See the Shuup or Django-Jinja documentation on more information how to configure things correctly.' )
validate the templates configuration in the django settings .