Browse Source

Debug utility template tags.

backports/m1-live
Erik Stein 8 years ago
parent
commit
69b328225e
  1. 20
      utils/templatetags/debug_utils.py

20
utils/templatetags/debug_utils.py

@ -0,0 +1,20 @@
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
# Erik Stein <code@classlibrary.net>, 2009-2017
import ipdb
from django import template
register = template.Library()
@register.filter
def ipdb_inspect(value):
ipdb.set_trace()
return value
@register.simple_tag
def ipdb_set_breakpoint():
ipdb.set_trace()
Loading…
Cancel
Save