B
B
Ben_r0072018-06-22 12:07:40
Django
Ben_r007, 2018-06-22 12:07:40

Why does an error occur when including an application in a Django project?

There is a project FirstProject. It has the FirstApp application.
Here is the list of INSTALLED_APPS from FirstProject/settings.py:

INSTALLED_APPS = [
    'django.contrib.admin',
    'django.contrib.auth',
    'django.contrib.contenttypes',
    'django.contrib.sessions',
    'django.contrib.messages',
    'django.contrib.staticfiles',
    'FirstApp',
]

Here is the error:
File "D:\DjangoVenv\FirstProject\FirstProject\urls.py", line 21, in
path('first/', include(FirstApp.urls)),
NameError: name 'FirstApp' is not
defined correct and what caused the error?
Thanks in advance!

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question