-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Provide a way to uncheck all checkboxes at once #1238
Comments
@Flimm Wouldn't the |
That does seem to work, thank you! Here is the configuration that I used: DEBUG_TOOLBAR_CONFIG = {
'DISABLE_PANELS': {
'debug_toolbar.panels.history.HistoryPanel',
'debug_toolbar.panels.versions.VersionsPanel',
'debug_toolbar.panels.timer.TimerPanel',
'debug_toolbar.panels.settings.SettingsPanel',
'debug_toolbar.panels.headers.HeadersPanel',
'debug_toolbar.panels.request.RequestPanel',
'debug_toolbar.panels.sql.SQLPanel',
'debug_toolbar.panels.staticfiles.StaticFilesPanel',
'debug_toolbar.panels.templates.TemplatesPanel',
'debug_toolbar.panels.cache.CachePanel',
'debug_toolbar.panels.signals.SignalsPanel',
'debug_toolbar.panels.logging.LoggingPanel',
'debug_toolbar.panels.redirects.RedirectsPanel',
'debug_toolbar.panels.profiling.ProfilingPanel',
},
} I found the list of panels here: https://django-debug-toolbar.readthedocs.io/en/latest/panels.html |
@Flimm what's the purpose behind this? Please don't install the toolbar in a production environment even if all the panels are disabled. As a reminder, the toolbar does some monkey patching that gets applied regardless if it's imported (logging panel). |
The debug toolbar significantly slows down the response on my developer machine, especially when there are many database queries. That's why I wanted to disable the slow panels. You say that django-debug-toolbar in a production environment should not even be installed. Do you mean even just doing |
No, the code needs to be imported into your project. So if it's added in the INSTALLED_APPS, MIDDLEWARE, urls.py. |
Thanks. Either way, the installation instructions do not make it clear. They do not say that if not os.environ.get('IN_PRODUCTION'):
INSTALLED_APPS.append('debug_toolbar')
MIDDLEWARE.insert(0, "debug_toolbar.middleware.DebugToolbarMiddleware") and in if not os.environ.get('IN_PRODUCTION'):
urlpatterns.append(path('__debug__/', include('debug_toolbar.urls'))) |
You're right. We should get that changed as a part of #1435. |
The Django side-bar provides a list of checkboxes, most of which are ticked by default:
Some of these things can slow down the time it takes for the response to return. For this reason, I often find myself wanting to untick all the checkboxes. This is a laborious process.
Every time I restore the database from backup, I need to re-do this process again.
The text was updated successfully, but these errors were encountered: