Python pdb and Breakpoint Cheat Sheet/Disable or enable a breakpoint

Toggle an existing breakpoint by number.

Section: Breakpoints and Navigation

Disable or enable a breakpoint

text
text
disable 1
enable 1

Learn the surrounding workflow

Compare similar commands or jump into common fixes when this command is part of a bigger troubleshooting path.

Related commands

Same sheet · prioritizing Breakpoints and Navigation
Break on a line number
Set a line breakpoint in the current file.
OpenIn sheettextsame section
Break on function entry
Stop when a function is entered.
OpenIn sheettextsame section
Conditional breakpoint
Pause only when a condition is true.
OpenIn sheettextsame section
Clear a breakpoint
Remove one breakpoint or all breakpoints.
OpenIn sheettextsame section
Jump to another line
Change the next line to be executed in the current frame.
OpenIn sheettextsame section
Start pdb from CLI
Debug a script from the command line.