0

I need to find Django TEMPLATES location to add in a line under 'context_processors' om 'OPTIONS'

I researched and found this which looks to be my problem solver, however I am unable to find the location of the document where I am supposed to input the details specified: django.core.exceptions.ImproperlyConfigured: Enable 'django.contrib.auth.context_processors.auth'

The project only relies on Django as a plugin so I am in no means experienced with setting up Django.

TEMPLATES = [
    {
        'BACKEND': 'django.template.backends.django.DjangoTemplates',
        'DIRS': [os.path.join(BASE_DIR, 'templates')],
        'APP_DIRS': True,
        'OPTIONS': {
            'context_processors': [
                "django.contrib.auth.context_processors.auth",
            ]
        }
    }
]

I can

not find the 'TEMPLATES' document.

Frederik1111
  • 49
  • 1
  • 4

1 Answers1

2

You put all project configurations in settings.py right at the top of the project

Mohammad hp
  • 446
  • 4
  • 16
  • Thank you, but I can only seem to find the template for the settings: settings.py.tpl - and to my surprise, even in this file the necessary line already is present. I get the error when running cuckoo webserver (using mongodb) in the very beginning when it is performing system checks, if thats to any help. I imagine the django settings.py is to find in my 'project' somewhere, would that be in the mongodb data somewhere? – Frederik1111 Aug 13 '19 at 10:13