Note that the Win32 module is reported as being used on line 624 of file Bar.pm. Not only does that file contain no mention of Win32; but it’s only 24 lines long! How does the call find an unmentioned module on a non-existent line of code?

Win32.pm is an unusual module. It doesn't need to be loaded, to be used:

C:\test>perl -E"say Win32::GetOSVersion();" Service Pack 16060012107681

It is effectively demand-loaded. And that is probably the source of the problem. At some point in the process of loading the used modules, Win32 get demand loaded in order to satisfy some requirement of one of those used modules; and in the process, Win32 gets added to %INC.

Module::Info detects the presence/addition of Win32 and throws its hands up in horror.

If its purpose is to check that a certain set of required modules can be loaded -- a pointless test as they would be detected and clearly flagged by the standard Perl mechanisms anyway -- but if that is its purpose, it should stick to doing that. And only that.

There is no sense in calling foul because an extra module is loaded. That is none of its business with respect to its defined purpose.

Module::Info, like so many of the modules in the Module::* namespace is developed by *nix programmer without reference to, or concern for, anything outside that platform. Also, like so many of them, it is "testing" something that it is pointless to test. Something that if it failed, Perl's standard error reporting mechanisms would detect and report anyway; and in a far clearer and more usable fashion.

The best solution -- and I do mean best; not simplest or most convenient -- would be to disable all the tests that are dependent upon Module::Info; and refuse to allow it on your systems. It does things it shouldn't do.


With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'
Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
"Science is about questioning the status quo. Questioning authority".
In the absence of evidence, opinion is indistinguishable from prejudice.
I'm with torvalds on this Agile (and TDD) debunked I told'em LLVM was the way to go. But did they listen!

In reply to Re: Installing Module::Info 0.35 for Strawberry Perl 5.22.0 by BrowserUk
in thread Installing Module::Info 0.35 for Strawberry Perl 5.22.0 by Athanasius

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.