in reply to Using Data::Printer from the Perl debugger

G'day ibm1620,

I can replicate your results.

I made a verbatim copy of foo.pl (including shebang and v5.36). I have the latest versions of DB::Pluggable (1.112001) & Data::Printer (1.001000). I get identical output to what you show for 'perl -d ./foo.pl'.

I also tried with .perldb code formatted as shown in DB::Pluggable - SYNOPSIS. The result was the same ("prints twice") except, of course, for:

DB<2> c Here is ~/.perldb: use DB::Pluggable; DB::Pluggable->run_with_config(\<<EOINI); [DataPrinter] EOINI main::(./foo.pl:10): my $foo = 1; # set breakpoint here and issue p + @xx
"I get the same result when I remove the last 3 lines from foo.pl"

My result starts the same but ends with:

DB<3> c Debugged program terminated. Use q to quit or R to restart,

I don't see this as being related to "prints twice"; however, it might be worth checking that the code you posted is the same as what you're running. After removing 3 lines, my last statement is 'my $foo = 1;'.

— Ken