Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight
 
PerlMonks  

Modern::Perl version 2011 required--this is only version 1.03 at my-perl-script.cgi

by taint (Chaplain)
on Nov 05, 2013 at 15:46 UTC ( #1061320=perlquestion: print w/ replies, xml ) Need Help??
taint has asked for the wisdom of the Perl Monks concerning the following question:

Greetings monks,
I've been reading chromatic "Modern Perl 2011-2012 edition" -- thank you chromatic! So in deciding to take the advice at the very beginning of the book, I added
use Modern::Perl 2011;
as stated, this translates to:
use 5.012; # implies "use strict;" use warnings;
Seems reasonable. I'm useing 5.12.5, and I always use warn.
But after adding that line, I receive the following error in a script that never complained before:
Modern::Perl version 2011 required--this is only version 1.03
Of course I'll reaquaint myself with the Modern::Perl docs. But just thought I'd mention it here, as it is quite unexpected.

Thank you for all your time, and consideration.

--Chris

#!/usr/bin/perl -Tw
use perl::always;
my $perl_version = "5.12.5";
print $perl_version;

Comment on Modern::Perl version 2011 required--this is only version 1.03 at my-perl-script.cgi
Select or Download Code
Re: Modern::Perl version 2011 required--this is only version 1.03 at my-perl-script.cgi
by moritz (Cardinal) on Nov 05, 2013 at 16:16 UTC
      Weird. He indicates in the book that everything works best with Perl 5.12.0 or newer. So I figured since my version of Modern::Perl (1.03) came with my version of Perl (5.12.5), everything would be "hunky-dory".

      --Chris

      #!/usr/bin/perl -Tw
      use perl::always;
      my $perl_version = (5.12.5);
      print $perl_version;

        Whomever built "(your) version of Perl (5.12.5)", might have included the older version. M::P does not come along with perl 5.16.3; it is also missing from 5.12.5 per module list. FWIW, current version is 1.20121103 on CPAN; also, no "2011" version is listed there.

        I figured since my version of Modern::Perl (1.03) came with my version of Perl (5.12.5)...

        It's not a core module, so someone bundled it with your version of Perl. Unfortunately, the bundled version predates the year specifier. Upgrading to the most recent Modern::Perl version will let you use a year specifier (and it will be quick and easy).

Re: Modern::Perl version 2011 required--this is only version 1.03 at my-perl-script.cgi
by ww (Bishop) on Nov 05, 2013 at 17:08 UTC
    Best I can tell, there is no Modern::Perl version 2011. I think you've confused the date (or, rather ,part of the date) in the title you cite with a version number.

    Both CPAN and ppm list Modern::Perl-1.20121103 (for perl 5.016); a naming convention which may clarify the problem.

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others chanting in the Monastery: (5)
As of 2015-07-04 09:14 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (59 votes), past polls