Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

comment on

( [id://3333]=superdoc: print w/replies, xml ) Need Help??
Carp::Always is a minimalist debugging aid, often used from the command line with usage patterns like
perl -MCarp::Always script.pl
or
PERL5OPT=-MCarp::Always script.pl
Using Carp::Always decorates the output of each warn() and die() with stacktraces. For example,
$ perl -MCarp::Always -e 'sub f { die "arghh" }; sub g { f }; g;' arghh at -e line 1 main::f() called at -e line 1 main::g() called at -e line 1

This is meant to help finding where issues actually coming from at the code being inspected.

Last week I had the chance to revisit Carp::Always code. It was basically abandoned since the 0.13 release back in 2013. One could say that there was not much work to do about it and that it withstood the test of times as many other CPAN modules that haven't seen updates in a long time. That is not quite true: the bug backlog kept growing and it is quite possible that the few Carp::Always users may have disbanded to newer alternatives like Devel::Confess.

The main changes in the latest 0.16 release are:

  • Fix for a long standing bug with duplicate tracebacks - see a mention of it in the 2011 Perl Advent
  • Carp::Always now enabled / disabled by import() / unimport() rather than using BEGIN and END blocks

The bug backlog has been cleared (both at GitHub and CPAN RT queue) to make room for brand new bugs. =)

Hopefully, these updates will extend Carp::Always lifetime and usefulness. You're invited to give it a try.


In reply to Carp::Always comeback by ferreira

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":



  • Are you posting in the right place? Check out Where do I post X? to know for sure.
  • Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
    <code> <a> <b> <big> <blockquote> <br /> <dd> <dl> <dt> <em> <font> <h1> <h2> <h3> <h4> <h5> <h6> <hr /> <i> <li> <nbsp> <ol> <p> <small> <strike> <strong> <sub> <sup> <table> <td> <th> <tr> <tt> <u> <ul>
  • Snippets of code should be wrapped in <code> tags not <pre> tags. In fact, <pre> tags should generally be avoided. If they must be used, extreme care should be taken to ensure that their contents do not have long lines (<70 chars), in order to prevent horizontal scrolling (and possible janitor intervention).
  • Want more info? How to link or How to display code and escape characters are good places to start.
Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others romping around the Monastery: (5)
As of 2024-04-19 15:40 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found