Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Django Debug toolbar shows up, but the panels return 404

It was working in the last couple of days, but now all the links on the toolbar themselves are just #

<li class="djDebugPanelButton active">
<input type="checkbox" data-cookie="djdtSQLPanel" checked="checked" title="Disable for next and successive requests">
    <a href="#" title="SQL queries from 1 connection" class="SQLPanel">SQL<br><small>215 queries in 174.10ms</small></a>
</li>

I've set it up explicitly like this says: http://django-debug-toolbar.readthedocs.org/en/1.0/installation.html#explicit-setup

I don't get the djdt namespace issue in fact I get no errors at all, except the 404 when I try to view one of the panels.....

like image 572
boatcoder Avatar asked Mar 28 '14 06:03

boatcoder


1 Answers

Placing:

if settings.DEBUG:
    import debug_toolbar
    urlpatterns = patterns(
        '',
        url(r'^__debug__/', include(debug_toolbar.urls)),)

before all other URLs did the trick for me. Then:

urlpatterns += patterns(...)

for the rest of the URLs, like django-cms, etc.

Or if you prefer to place debug_toolbar implementation at the end of the file urlpatterns = patterns('', url...) + urlpatterns.

like image 156
2 revs Avatar answered Sep 20 '22 18:09

2 revs