You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Django plugin that installs and configures the Django Debug Toolbar
Goal
The Django Debug Toolbar is amazingly useful for development. It's so powerful that it's very dangerous to activate it in production.
The goal of this plugin is to enable a developer to activate the Django Debug Toolbar with the minimum number of steps, while keeping debug related code out of the codebase.
This plugin injects the Debug Toolbar Middleware early, but not too early, in the middleware list.
It needs to run after any midddleware that decodes requests (GZipMiddleware), or sets request.META['REMOTE_ADDR'] (like django-xforwardedfor-middleware or django-xff).
If you have any other middleware that needs to run before the Debug Toolbar Middleware, please open a ticket and we'll add it to the TOOLBAR_MUST_GO_AFTER list.
Development
To set up this plugin locally, first checkout the code. Then create a new virtual environment:
cd django-plugin-django-debug-toolbar
python -m venv venv
source venv/bin/activate
Now install the dependencies and test dependencies:
pip install -e '.[test]'
To run the tests:
python -m pytest
About
Django plugin that configures the Django Debug Toolbar