Cirollo has asked for the wisdom of the Perl Monks concerning the following question:

Over the past few months, I've become slightly familiar with the perl command line debugger, but sometimes it seems limiting or unwieldy.

Are there any debugging tools out there that are better than or enhance the built-in debugger? I've heard good things about DDD, the graphical debugger...would that be my best choice, or is there something better?

I don't have a specific application in mind for this, I just want to know if there is some way to make debugging faster and more efficient (in terms of my time).

Replies are listed 'Best First'.
Re: Debugging utils
by eduardo (Curate) on Aug 04, 2000 at 01:04 UTC
    DDD is quite easilly the best debugger that I have ever used in the unix enviroment. The ability to graphically display complex data structures has saved my ass more than once, not to mention countless hours of development time. Just remember, debugging is not something that you do once development is done, this is an iterative process :)

    I should also add, remember, DDD (and most other 3rd party debuggers) are just value added front ends to the already existing, maybe not so damned friendly tools!

RE: Debugging utils
by mrmick (Curate) on Aug 04, 2000 at 04:36 UTC
    There's also the graphical debugger offered by ActiveState for WIN32. It works great! If you are doing any development on WIN32, I recommend this.

    I'm not sure whether they are planning to port this to other platforms but it seems to be a logical step in the right direction if they are going to port ActivePerl.

    Mick
Re: Debugging utils
by splinky (Hermit) on Aug 04, 2000 at 06:56 UTC
    ptkdb is available from CPAN. It was written up in The Perl Journal a year or so ago and, IIRC, the author won a prize for his paper at The Perl Conference last year.

    *Woof*

Re: Debugging utils
by jeorgen (Pilgrim) on Aug 04, 2000 at 15:12 UTC
    ptkdb puts a graphical interface on the debugger, and I really like it. I've noticed some problems with getting all the panes to show on some installations on win32. The textsize, selection color and font by default on Win32 are not good choices, but these can be altered with some hacking.

    It's definitely worth a try!

    /jeorgen

RE: Debugging utils
by meonkeys (Chaplain) on Aug 04, 2000 at 05:29 UTC
    Could you recommend me a good book/website/etc. on Perl debugging? I'm very confused by the perldebug manpage.
      Whats confusing you?

      Learning Perl and Perl in a Nutshell both have small sections to get you started, but they're pretty similar to the perldebug manpage.

      To get started in the debugger, 'n' executes the next command, skipping over subroutines. Note that the command printed in the debugger is the one thats about to get executued. 's' works like 'n' except it descends into subroutines.

      'c' continues exectution until the program breaks or you get to a breakpoint; 'b line' sets a breakpoint, 'D' clears all your breakpoints.

      Remember that you can also type in normal Perl statements and they will get executed.

      Hopefully that will get you started and you can go back to the manpage for more info...