I want to show debug tool bar but it looks like above.. what's wrong?
Asked
Active
Viewed 118 times
0
-
Did you run `python manage.py collectstatics`? – kichik Apr 08 '22 at 01:16
-
I did that, And I finally can get desired results. Thanks alot !!!!!!!!!!! – yuuum Apr 11 '22 at 08:34
1 Answers
0
First, be sure you have 'django.contrib.staticfiles' in your INSTALLED_APPS (settings.py)
INSTALLED_APPS = [
# ...
"django.contrib.staticfiles",
# ...
]
STATIC_URL = "static/"
Check you have "django.template.backends.django.DjangoTemplates" and "APP_DIRS": True in your template config inside settings.py
TEMPLATES = [
{
"BACKEND": "django.template.backends.django.DjangoTemplates",
"APP_DIRS": True,
# ...
}
]
Add "debug_toolbar" to your INSTALLED_APPS settings.py
INSTALLED_APPS = [
# ...
"debug_toolbar",
# ...
]
Add django-debug-toolbar’s URLs to your project’s URLconf [urls.py, or any url file:)]
from django.urls import include, path
urlpatterns = [
# ...
path('__debug__/', include('debug_toolbar.urls')),
]
Add the Middleware (settings.py)
MIDDLEWARE = [
# ...
"debug_toolbar.middleware.DebugToolbarMiddleware",
# ...
]
Configure Internal IPs add this config to settings.py
INTERNAL_IPS = [
# ...
"127.0.0.1",
# ...
]
Should be working now ;)
More info https://django-debug-toolbar.readthedocs.io/en/latest/installation.html

Eduardo Alejandro Leyva
- 449
- 4
- 11