[Fixed]-Does not appear to have any patterns in it. If you see valid patterns in the file then the issue is probably caused by a circular import

4👍

Your import is incorrect. The views.py containing login and logout is in the django.contrib.auth app:

from django.contrib.auth.views import login, logout

3👍

just check whether urlpattern and change into patterns

👤MR.D

2👍

It is caused by errors in views.py file as code code redirect link isn’t properly working.
so,Check views file to remove error

0👍

In your outermost urls file, if you are including other package urls like

path("accounts/", include("UserDataAPI.urls"))

or

url(r'^accounts/', include('accounts.urls'))

Ensure that in accounts.urls module or UserDataAPI.urls modules you have declared the urlpatterns variable

Leave a comment