MCPcopy Index your code
hub / github.com/ipython/ipython / break_anywhere

Method break_anywhere

IPython/core/debugger.py:1087–1104  ·  view source on GitHub ↗

_stop_in_decorator_internals is overly restrictive, as we may still want to trace function calls, so we need to also update break_anywhere so that is we don't `stop_here`, because of debugger skip, we may still stop at any point inside the function

(self, frame)

Source from the content-addressed store, hash-verified

1085 do_w = do_where
1086
1087 def break_anywhere(self, frame):
1088 """
1089 _stop_in_decorator_internals is overly restrictive, as we may still want
1090 to trace function calls, so we need to also update break_anywhere so
1091 that is we don't `stop_here`, because of debugger skip, we may still
1092 stop at any point inside the function
1093
1094 """
1095
1096 sup = super().break_anywhere(frame)
1097 if sup:
1098 return sup
1099 if self._predicates["debuggerskip"]:
1100 if DEBUGGERSKIP in frame.f_code.co_varnames:
1101 return True
1102 if frame.f_back and self._get_frame_locals(frame.f_back).get(DEBUGGERSKIP):
1103 return True
1104 return False
1105
1106 def _is_in_decorator_internal_and_should_skip(self, frame):
1107 """

Callers

nothing calls this directly

Calls 2

_get_frame_localsMethod · 0.95
getMethod · 0.80

Tested by

no test coverage detected