Newbie

Diez B. Roggisch deets at nospam.web.de
Tue Aug 8 08:07:35 EDT 2006


pranav wrote:

> Hi,
> I am new to python. I wanted to know how can i debug a python program.
> Is there a gdb equivalent?

pdb, a standard module.

I use it like this:


def some_method_I_want_to_debug():
    import pdb
    pdb.set_trace()
    # more code to come


But that is only one way of using it - read the docs.

Diez



More information about the Python-list mailing list