Something very odd just happened. I fired up a script that I used just a few weeks ago. It calls mods:
use feature ':5.10'; use URL::Encode qw(url_encode); use Storable qw(nstore retrieve); use Date::Manip; use LWP::UserAgent; use Math::Round qw(round); use JSON::XS;
When I run the script it says Can't locate URL/Encode.pm in @INC (you may need to install the URL::Encode module). If I comment-out the second line it throws the same error for Date::Manip. I run cpan -l and there they are!

It's not that the env variable $PATH got screwed up, because if I comment-out Date::Manip too it finds the other mods. This has me scratching my head. What could explain it?

Update

I found that if I run it from the command like so perl program.pl it finds the mods. But if I run it like so program.pl it doesn't. So I'm guessing must be something wrong with the file association to *.pl. I wonder how to fix that.

In reply to Interpreter can't find known installed mods (w10) by cormanaz

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



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.