Skip to content


Subversion checkout URL

You can clone with
Download ZIP


Allow profiler max depth to be set in settings #515

wants to merge 1 commit into from

2 participants


Sometimes it's helpful to have a max depth of more than 10, which is currently hard-coded in the profiling panel.


Yes. The patch needs documentation.

@aaugustin aaugustin closed this in #560
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Dec 28, 2013
  1. @mjumbewu
This page is out of date. Refresh to see the latest.
Showing with 3 additions and 1 deletion.
  1. +3 −1 debug_toolbar/panels/
4 debug_toolbar/panels/
@@ -3,6 +3,7 @@
from django.utils.translation import ugettext_lazy as _
from django.utils.safestring import mark_safe
from debug_toolbar.panels import Panel
+from debug_toolbar import settings as dt_settings
import cProfile
from pstats import Stats
@@ -152,6 +153,7 @@ def process_response(self, request, response):
root = FunctionCall(self.stats, self.stats.get_root_func(), depth=0)
func_list = []
- self.add_node(func_list, root, 10, root.stats[3] / 8)
+ max_depth = dt_settings.CONFIG.get('PROFILER_MAX_DEPTH', 10)
+ self.add_node(func_list, root, max_depth, root.stats[3] / 8)
self.record_stats({'func_list': func_list})
Something went wrong with that request. Please try again.