Return True if there is an effective breakpoint for this line. Check for line or function breakpoint and if in effect. Delete temporary breakpoints if effective() says to.
(self, frame)
| 444 | return False |
| 445 | |
| 446 | def break_here(self, frame): |
| 447 | """Return True if there is an effective breakpoint for this line. |
| 448 | |
| 449 | Check for line or function breakpoint and if in effect. |
| 450 | Delete temporary breakpoints if effective() says to. |
| 451 | """ |
| 452 | filename = self.canonic(frame.f_code.co_filename) |
| 453 | if filename not in self.breaks: |
| 454 | return False |
| 455 | lineno = frame.f_lineno |
| 456 | if lineno not in self.breaks[filename]: |
| 457 | # The line itself has no breakpoint, but maybe the line is the |
| 458 | # first line of a function with breakpoint set by function name. |
| 459 | lineno = frame.f_code.co_firstlineno |
| 460 | if lineno not in self.breaks[filename]: |
| 461 | return False |
| 462 | |
| 463 | # flag says ok to delete temp. bp |
| 464 | (bp, flag) = effective(filename, lineno, frame) |
| 465 | if bp: |
| 466 | self.currentbp = bp.number |
| 467 | if (flag and bp.temporary): |
| 468 | self.do_clear(str(bp.number)) |
| 469 | return True |
| 470 | else: |
| 471 | return False |
| 472 | |
| 473 | def do_clear(self, arg): |
| 474 | """Remove temporary breakpoint. |
no test coverage detected