Created
January 23, 2021 04:10
-
-
Save ManotLuijiu/2bb689a20342b8bbb70765891b23b8c4 to your computer and use it in GitHub Desktop.
Django [project-name]/urls.py
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from django.contrib.staticfiles.storage import staticfiles_storage | |
from django.views.generic.base import RedirectView | |
from django.contrib import admin | |
from django.urls import path, include | |
from leads.views import landing_page | |
def trigger_error(request): | |
division_by_zero = 1 / 0 | |
urlpatterns = [ | |
path("favicon.ico", RedirectView.as_view( | |
url=staticfiles_storage.url("favicon.ico"))), | |
path('sentry-debug/', trigger_error), | |
path('admin/', admin.site.urls), | |
path('', landing_page, name='landing_page'), | |
path('leads/', include('leads.urls', namespace="leads")) | |
] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment