I’m new to Django and I’m facing a problem that I can’t solve despit my research… I’v already made small django projects without this error but since I reformat my computer (I can’t see the link but that’s context!) i’m having this problem.
So when I’m running (runserver) a django project this is what my browser shows me despite others urls in my project
I’v tried with an almost empty project but a least one more url and still have the same page.
urls.py in the main file (src/mynotes/urls.py):
from django.contrib import admin
from django.urls import path, include
urlpatterns = [
settings.py in the main project (src/mynotes/settings.py):
INSTALLED_APPS = [
urls.py in the app (src/dbnotes/urls.py):
from django.urls import path
from . import views
urlpatterns = [
path(“”, views.homepage, name=“homepage”),
views.py in the app (src/dbnotes/views.py):
from django.http import HttpResponse
return HttpResponse(“Hello, world. You’re at the polls index.”)
Even stranger, when i change “path(‘admin/’, admin.site.urls)” I still get the admin page with the same route. Even if i change ‘admin/’ or admin.site.urls.
It looks like my local server display an over empty django project but in the error page it’s written “mynotes.urls” as the url location which is the good folder.
I’m working with a virtual environment.
I’m lost as it’s the first time i got this issue despite having created ohter (small) django projects!
If anyone has an idea that would be great! Thank you!
I found a topic related to my problem but without an anwer : Django doesn’t see urls.py