##// END OF EJS Templates
Sprinkle deprecation warnings stacklevel in the debugger....
Matthias Bussonnier -
Show More
@@ -63,7 +63,7 b' def BdbQuit_excepthook(et, ev, tb, excepthook=None):'
63 parameter.
63 parameter.
64 """
64 """
65 warnings.warn("`BdbQuit_excepthook` is deprecated since version 5.1",
65 warnings.warn("`BdbQuit_excepthook` is deprecated since version 5.1",
66 DeprecationWarning)
66 DeprecationWarning, stacklevel=2)
67 if et==bdb.BdbQuit:
67 if et==bdb.BdbQuit:
68 print('Exiting Debugger.')
68 print('Exiting Debugger.')
69 elif excepthook is not None:
69 elif excepthook is not None:
@@ -76,7 +76,7 b' def BdbQuit_excepthook(et, ev, tb, excepthook=None):'
76 def BdbQuit_IPython_excepthook(self,et,ev,tb,tb_offset=None):
76 def BdbQuit_IPython_excepthook(self,et,ev,tb,tb_offset=None):
77 warnings.warn(
77 warnings.warn(
78 "`BdbQuit_IPython_excepthook` is deprecated since version 5.1",
78 "`BdbQuit_IPython_excepthook` is deprecated since version 5.1",
79 DeprecationWarning)
79 DeprecationWarning, stacklevel=2)
80 print('Exiting Debugger.')
80 print('Exiting Debugger.')
81
81
82
82
@@ -128,7 +128,7 b' class Tracer(object):'
128 """
128 """
129 warnings.warn("`Tracer` is deprecated since version 5.1, directly use "
129 warnings.warn("`Tracer` is deprecated since version 5.1, directly use "
130 "`IPython.core.debugger.Pdb.set_trace()`",
130 "`IPython.core.debugger.Pdb.set_trace()`",
131 DeprecationWarning)
131 DeprecationWarning, stacklevel=2)
132
132
133 ip = get_ipython()
133 ip = get_ipython()
134 if ip is None:
134 if ip is None:
General Comments 0
You need to be logged in to leave comments. Login now