Closed PHermans1 closed 1 year ago
Thanks for reporting this issue, don't forget to star this project if you haven't already to help us reach a wider audience.
@PHermans1 I believe the error here means that you need to add app_name
to your urls.py
.
Take a look at the demo application for a more detailed example of how to set up your urls.py
NOTE:
app_name
shouldn't be added to theConferenceListView
as it's not utilized by the view but by the route config.
Is there an existing issue for this?
Does this issue exist in the latest version?
Describe the bug?
Django 4, bootstrap5
settings.py file: ROOT_URLCONF = 'main.urls'
in main/urls.py: app_name="main" urlpatterns = [ ... path('conferences/', main_views.ConferenceListView.as_view(), name='conferences_list'), ...]
in my view.py: class ConferenceListView(LoginRequiredMixin, PermissionRequiredMixin, ListBreadcrumbMixin, ListView): model = Conference template_name = 'conference/conference_list.html' permission_required = ('main.do_student_things',) app_name = "main" ...
everything works fine and as expected until I added the "ListBreadCrumbMixin" to this view. If I remove it, all works fine again.
I am unclear as to where I am supposed to define the app_name to make it work, but it is not doing so even though I have defined it in they urls.py and the view
Any guidance would be welcome. Thanks
To Reproduce
1) Run server 2) home page crashes with the error 'main' is not a registered namespace
What OS are you seeing the problem on?
macOS
Expected behavior?
Simply to have a breadcrumb for my listView class
Relevant log output
Anything else?
I am happy to send entire files, but don't see how I do that here.
Code of Conduct