Beefy Boxes and Bandwidth Generously Provided by pair Networks vroom
There's more than one way to do things
 
PerlMonks  

Re: When my script doesn't work, I ...

by Anique (Acolyte)
on Oct 02, 2012 at 10:20 UTC ( #996832=note: print w/ replies, xml ) Need Help??


in reply to When my script doesn't work, I ...

Debug until I drop
(includes writing say 'Checkpoint 1'; every other line - increasing the number of course)
Go home about five minutes before the office closes
Get back to work next morning (after dreaming about bugs)
Look at code for a few minutes
Find the obvious bug (often assignment instead of comparison, or using the wrong variable name)
Smack myself
Do happy dance that everything works now
Further development
Create bug
restart cycle...


Comment on Re: When my script doesn't work, I ...
Download Code
Re^2: When my script doesn't work, I ...
by Tux (Monsignor) on Oct 05, 2012 at 10:10 UTC

    You should use Devel::Trace. That would save you a lot of adding checkpoints :)

    FWIW, I also use the invaluable Devel::TraceUse to find out why a script works flawless on machine A where it fails on machine B and quite often find out that it isn't my code that fails, but a bad/old module that is not updated on machine B.


    Enjoy, Have FUN! H.Merijn

      Thanks for the tip! I'll look into that.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://996832]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others pondering the Monastery: (6)
As of 2014-04-18 00:44 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    April first is:







    Results (460 votes), past polls