Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Perl > Perl Misc > Help: Debug perl codes

Reply
Thread Tools

Help: Debug perl codes

 
 
Amy Lee
Guest
Posts: n/a
 
      08-17-2008
Hello,

Is there any way to debug perl codes like shell script with "sh -x"?

Thank you very much~

Best Regards,

Amy
 
Reply With Quote
 
 
 
 
Jürgen Exner
Guest
Posts: n/a
 
      08-17-2008
Amy Lee <(E-Mail Removed)> wrote:
>Is there any way to debug perl codes like shell script with "sh -x"?


Is there anything wrong with the answer to 'perldoc -q debug':
How do I debug my Perl programs?

jue
 
Reply With Quote
 
 
 
 
Tad J McClellan
Guest
Posts: n/a
 
      08-17-2008
Amy Lee <(E-Mail Removed)> wrote:


> Is there any way to debug perl codes like shell script with "sh -x"?



Please do not continue to use this newsgroup as a service
that reads the docs to you.

Make at least some small effort to answer your questions yourself
before resorting to asking here.

Have you seen the Posting Guidelines that are posted here frequently?


perldoc -q debug

How do I debug my Perl programs?


--
Tad McClellan
email: perl -le "print scalar reverse qq/moc.noitatibaher\100cmdat/"
 
Reply With Quote
 
Peter Scott
Guest
Posts: n/a
 
      08-17-2008
On Sun, 17 Aug 2008 12:52:11 +0000, Jürgen Exner wrote:
> Amy Lee <(E-Mail Removed)> wrote:
>>Is there any way to debug perl codes like shell script with "sh -x"?

>
> Is there anything wrong with the answer to 'perldoc -q debug':
> How do I debug my Perl programs?


Perhaps that it doesn't answer Amy's question? She wants:

Devel::Trace Print out each line before it is executed (like sh -x)

http://search.cpan.org/~mjd/Devel-Trace-0.10/

--
Peter Scott
http://www.perlmedic.com/
http://www.perldebugged.com/

 
Reply With Quote
 
Jürgen Exner
Guest
Posts: n/a
 
      08-17-2008
Peter Scott <(E-Mail Removed)> wrote:
>On Sun, 17 Aug 2008 12:52:11 +0000, Jürgen Exner wrote:
>> Amy Lee <(E-Mail Removed)> wrote:
>>>Is there any way to debug perl codes like shell script with "sh -x"?

>>
>> Is there anything wrong with the answer to 'perldoc -q debug':
>> How do I debug my Perl programs?

>
>Perhaps that it doesn't answer Amy's question? She wants:


Fair enough.

> Devel::Trace Print out each line before it is executed (like sh -x)


Because 'sh' is not a Perl command if would have helped to explain what
it does, just like you did in just half a sentence.

jue
 
Reply With Quote
 
Amy Lee
Guest
Posts: n/a
 
      08-17-2008
On Sun, 17 Aug 2008 13:39:03 +0000, Peter Scott wrote:

> On Sun, 17 Aug 2008 12:52:11 +0000, Jürgen Exner wrote:
>> Amy Lee <(E-Mail Removed)> wrote:
>>>Is there any way to debug perl codes like shell script with "sh -x"?

>>
>> Is there anything wrong with the answer to 'perldoc -q debug':
>> How do I debug my Perl programs?

>
> Perhaps that it doesn't answer Amy's question? She wants:
>
> Devel::Trace Print out each line before it is executed (like sh -x)
>
> http://search.cpan.org/~mjd/Devel-Trace-0.10/

Thanks. I need this module to debug a script. Thanks to Jue~

Amy
 
Reply With Quote
 
Michael Carman
Guest
Posts: n/a
 
      08-19-2008
Thrill5 wrote:
> "Tad J McClellan" <(E-Mail Removed)> wrote:
>> Please do not continue to use this newsgroup as a service
>> that reads the docs to you.
>>
>> Make at least some small effort to answer your questions yourself
>> before resorting to asking here.

>
> Or else what? You'll stop posting and we all wont be able to read your
> rants anymore?
>
> Waahhhh!!!


Don't mock. Many highly knowledgeable Perl programmers *have* stopped
posting here -- to everyones loss -- because they've grown weary of
answering the same questions ad nauseum and of self-righteous whiners
throwing tantrums when they are told to RTFM.

I'd rather lose them than Tad.

-mjc
 
Reply With Quote
 
Amy Lee
Guest
Posts: n/a
 
      08-20-2008
On Tue, 19 Aug 2008 20:47:26 -0400, Thrill5 wrote:

>
> "Michael Carman" <(E-Mail Removed)> wrote in message
> news:Sfyqk.304706$yE1.66653@attbi_s21...
>> Thrill5 wrote:
>>> "Tad J McClellan" <(E-Mail Removed)> wrote:
>>>> Please do not continue to use this newsgroup as a service
>>>> that reads the docs to you.
>>>>
>>>> Make at least some small effort to answer your questions yourself
>>>> before resorting to asking here.
>>>
>>> Or else what? You'll stop posting and we all wont be able to read your
>>> rants anymore?
>>>
>>> Waahhhh!!!

>>
>> Don't mock. Many highly knowledgeable Perl programmers *have* stopped
>> posting here -- to everyones loss -- because they've grown weary of
>> answering the same questions ad nauseum and of self-righteous whiners
>> throwing tantrums when they are told to RTFM.
>>
>> I'd rather lose them than Tad.
>>
>> -mjc

> If everyone were to RTFM then there wouldn't be any need to post any
> messages here in the first place. Everything about Perl is documented ad
> nauseam and at least a couple hundred books published on the subject. This
> is a public newsgroup where ANYONE can post a ANY question they want that is
> related to Perl even if it is printed in the ****ING MANUAL. If someone
> thinks the question is STUPID, SHUT THE **** UP and don't REPLY. No one is
> forcing anyone to answer any question. If your too think your too smart to
> answer stupid questions, don't waste YOUR time, or my bandwidth with a "your
> stupid because you didn't RTFM" answer. The only self-righteous douchbags
> on this newsgroups are the "highly knowledgeable Perl programmers" replying
> with RTFM.

Actually speaking, I have read the manual before I post my problem. But I
hope I can trace every sentence in my perl codes not just 'debug'.
However, I suppose that someone really did as misunderstood.

As I think, experts might more be patient to newbies, right?

Regards,

Amy
 
Reply With Quote
 
Sherm Pendley
Guest
Posts: n/a
 
      08-20-2008
Amy Lee <(E-Mail Removed)> writes:

> As I think, experts might more be patient to newbies, right?


In my experience, I've found that the experts here are *far* more
patient and helpful than the whiners claim. Sadly, no matter how
patient one is, or how many helpful fishing lessons one gives, there
will inevitably be someone in the audience who feels entitled to a
free fish dinner instead.

I suggest you keep reading a while - you'll quickly get a good feel
for who is helpful here, and who's a self-entitled crank. A good
indication of the latter is a half-shouted rant about how useless the
regulars are, like the one to which you responded.

sherm--

--
My blog: http://shermspace.blogspot.com
Cocoa programming in Perl: http://camelbones.sourceforge.net
 
Reply With Quote
 
Sherm Pendley
Guest
Posts: n/a
 
      08-20-2008
"Vernan R." <(E-Mail Removed)> writes:

> Sherm Pendley wrote:
>
>> Sadly, no matter how patient one is, or how many helpful fishing
>> lessons one gives, there will inevitably be someone in the
>> audience who feels entitled to a free fish dinner instead.

>
> I don't understand your reasoning. If you are saying the OP
> was seeking free fish, then you are clearly mistaken. If
> you are saying he who corected those presuming the question
> to be a FAQ, then you are also wrong.


Please don't put words in my mouth - if I had meant to say either of
those things, I would have. The OP's question was perfectly valid, not
in the FAQ, and those who directed her to the FAQ were mistaken.

There are a handful of people here who *did* demand answers that would
have been *trivially* answered with the most cursory search in the
docs. I'm not referring to the OP, but to those "defending" her
question by carrying on about how "mean" the regulars are. They've
behaved badly in the past, been slapped down for it, and now they're
carrying a grudge. As I said, it's easy to see who they are, by simply
watching the group for a while, and observing who tries to be helpful
and who does nothing but complain.

I don't think it's a problem that's endemic to this group, btw, just
human nature. In my experience, whenever you get a large enough group
of people together, there will inevitably be a few freeloaders and
whiners among them.

>> I suggest you keep reading a while - you'll quickly get a good feel
>> for who is helpful here, and who's a self-entitled crank. A good
>> indication of the latter is a half-shouted rant about how useless the
>> regulars are, like the one to which you responded.

>
> I never got the impression anyone was attempting to say that
> the "regulars", as you put it, are useless


Did you *read* the rant she responded to?

> instead of letting it be, you are defending the error?


Of course not. What I take objection to is the popular notion among
whiners (including the one to whom the OP had responded) that such
things are intentional attacks. The picture that these people paint,
of being irrationally "attacked" by regulars who "hate newbies," is
nothing but a ridiculous caricature.

sherm--

--
My blog: http://shermspace.blogspot.com
Cocoa programming in Perl: http://camelbones.sourceforge.net
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
how to write codes to connect access database using html codes hiralcp Software 0 12-18-2007 08:49 PM
How to use file I/o codes with form and controls codes Allen ASP .Net 1 12-03-2007 12:04 AM
Config Mgr Debug/Release and Web.config Compilation debug=true RonL ASP .Net 0 04-08-2006 03:50 PM
Virtual Key Codes, Scan Codes and ASCII Codes in C gj_williams2000@yahoo.co.uk C Programming 2 08-20-2005 11:04 AM
RegEx replace of html codes to ascii codes Greg -- ASP .Net 4 08-09-2005 07:27 PM



Advertisments