Skip to content

Instantly share code, notes, and snippets.

@cshoe
Created January 9, 2013 21:12
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save cshoe/4496988 to your computer and use it in GitHub Desktop.
Save cshoe/4496988 to your computer and use it in GitHub Desktop.
untracked.py
from .local import *
DEBUG = True
TEMPLATE_DEBUG = False
DJANGO_DEBUG_TOOLBAR = False
if DJANGO_DEBUG_TOOLBAR:
def extend_tuple(tuple_to_modify, *args):
# Use this function to simply add elements to an existing tuple
return tuple([item for item in tuple_to_modify] + [arg for arg in args])
MIDDLEWARE_CLASSES = extend_tuple(MIDDLEWARE_CLASSES, 'debug_toolbar.middleware.DebugToolbarMiddleware')
INSTALLED_APPS = extend_tuple(INSTALLED_APPS, 'debug_toolbar')
DEBUG_TOOLBAR_PANELS = (
'debug_toolbar.panels.version.VersionDebugPanel',
'debug_toolbar.panels.timer.TimerDebugPanel',
'debug_toolbar.panels.settings_vars.SettingsVarsDebugPanel',
'debug_toolbar.panels.headers.HeaderDebugPanel',
'debug_toolbar.panels.request_vars.RequestVarsDebugPanel',
'debug_toolbar.panels.template.TemplateDebugPanel',
'debug_toolbar.panels.sql.SQLDebugPanel',
'debug_toolbar.panels.signals.SignalDebugPanel',
'debug_toolbar.panels.logger.LoggingPanel',
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment