I
I
Ivan2015-11-08 20:34:15
Django
Ivan, 2015-11-08 20:34:15

url admin not working in django, what to do?

Hello. I decided to write a site, but there was a problem.
Wrote standard functionality:
project urls.py

from django.conf.urls import include, url
from django.contrib import admin

urlpatterns = [
    url(r'^admin/', include(admin.site.urls)),
    url(r'^event/', include('article.urls')),
]

The error appears as soon as I go to /admin/, and other urls work
TypeError at /admin/
argument to reversed() must be a sequence
Request Method: GET
Request URL: 127.0.0.1:8000/admin
Django Version: 1.8.5
Exception Type: TypeError
Exception Value:
argument to reversed() must be a sequence
Exception Location: C:\Users\Banek\AppData\Local\Programs\Python\Python35-32\lib\site-packages\django\core\urlresolvers.py in _populate, line 284
Python Executable: C:\Users\Banek\ AppData\Local\Programs\Python\Python35-32\python.exe
Python Version: 3.5.0
Python Path:
['D:\\GoogleD\\DjangoProject',
'D:\\GoogleD\\DjangoProject',
'C: \\Users\\Banek\\AppData\\Local\\Programs\\Python\\Python35-32\\python35.zip',
'C:\\Users\\Banek\\AppData\\Local\\Programs\\Python\\Python35-32\\DLLs',
'C:\\Users\\Banek\\AppData\\Local\\Programs\ \Python\\Python35-32\\lib',
'C:\\Users\\Banek\\AppData\\Local\\Programs\\Python\\Python35-32',
'C:\\Users\\Banek\ \AppData\\Local\\Programs\\Python\\Python35-32\\lib\\site-packages']

Answer the question

In order to leave comments, you need to log in

2 answer(s)
Z
zelsky, 2015-11-08
@zelsky

Move to urls admin to the end.

S
sim3x, 2015-11-09
@sim3x

urlpatterns = patterns(
    url(r'^admin/', include(admin.site.urls)),
    url(r'^event/', include('article.urls')),
)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question