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

Is it possible to drop to the debugger if a script is running and a certain condition is met ?

Replies are listed 'Best First'.
Re: dropping to the debugger from script?
by Fletch (Bishop) on Sep 24, 2008 at 15:22 UTC

    Look for the discussion of $DB::single in perldebug. Or you could be asking about watch expressions set with the w command (ibid). Question hazy . . .

    The cake is a lie.
    The cake is a lie.
    The cake is a lie.

      DB::single helps , but in order for it work the script should initially be ran with perl -d . Is it possible for it to work if I didn't start the script with the -d option ?