diff --git a/config/settings/base.py b/config/settings/base.py index 1257cbf..90fd365 100644 --- a/config/settings/base.py +++ b/config/settings/base.py @@ -51,6 +51,10 @@ DJANGO_MIDDLEWARE = [ MIDDLEWARE = DJANGO_MIDDLEWARE + PROJECT_MIDDLEWARE +if DEBUG: + INSTALLED_APPS += ["silk"] + DJANGO_MIDDLEWARE += ["silk.middleware.SilkyMiddleware"] + ROOT_URLCONF = "config.urls" TEMPLATES = [ diff --git a/config/tests/test_it_works.py b/config/tests/test_it_works.py deleted file mode 100644 index 24d0821..0000000 --- a/config/tests/test_it_works.py +++ /dev/null @@ -1,6 +0,0 @@ -from rest_framework.test import APITestCase - - -class TestItWorks(APITestCase): - def test_it_works(self): - assert 1 == 1 diff --git a/config/urls.py b/config/urls.py index 68537ce..3a44622 100644 --- a/config/urls.py +++ b/config/urls.py @@ -8,7 +8,7 @@ from django.urls import path, include urlpatterns = [ path("admin/", admin.site.urls), path("api/v1/", include("config.api.v1.urls")), - path("watchman", include("watchman.urls")), + path("watchman/", include("watchman.urls")), path("tpv/", include("tpv.urls", namespace="tpv")), path("auth/", include("users.urls", namespace="users")), ] @@ -16,3 +16,4 @@ urlpatterns = [ if settings.DEBUG: urlpatterns.append(path("__debug__/", include(debug_toolbar.urls))) urlpatterns += static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT) + urlpatterns += [path('silk/', include('silk.urls'))] diff --git a/requirements.txt b/requirements.txt index 91aa45f..aba2429 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,5 +1,5 @@ celery==5.4.0 -django==5.0.3 +django==5.0.6 django-cors-headers==3.13.0 django-cryptography==1.1 django-debug-toolbar==3.7.0 @@ -7,6 +7,7 @@ django-extensions==3.2.0 django-filter==23.1 django-environ==0.10.0 django-watchman==1.3.0 +django-silk==5.1.0 django-storages==1.13.2 django-unfold==0.12.0 dj-database-url==1.0.0