Debugging in Python is facilitated by pdb module (python debugger) which comes built-in to the Python standard library. It is actually defined as the class Pdb which internally makes use of bdb(basic debugger functions) and cmd (support for line-oriented command interpreters) modules. The major advantage of pdb is it runs purely in the command line, thereby making it great for debugging code on remote servers when we don’t have the privilege of a GUI-based debugger.
pdb supports:
- Setting breakpoints
- Stepping through code
- Source code listing
- Viewing stack traces
Shathana. S.R. Answered question July 7, 2023
