First, I simply understand that the machinery for getting modules installed is rather complex and must deal with differences in environments while implementing a data structure in Perl (without using XS) can easily be done in a way that is not sensitive to environment differences. So, the module having worked for one person while failing for another was simply more likely to be a problem with the installation machinery than with the functionality of a module for implementing a data structure.

So I downloaded Heap::Simple::Perl and ran "perl Makefile.PL" and then "make test" (actually "dmake test" in this case) under Windows and saw that all of the tests failed but the error messages were about not even being able to load modules. So the problems for my instance had nothing to do with the functioning of the module (since it seemed that the module under test wasn't even being found to be loaded). I find that actually reading error messages is very often useful in getting past problems (and I see even experienced software developers very often skip that simple step).

Next, I looked at the published test results for the module and saw that the majority of them pass. This reinforced my initial assessment. Next, I noticed that the first few failures I found listed were all on Windows. So the most likely explanation was that the process of getting the tests to run correctly was due to a quirk of Windows or of a common build of Perl on Windows. Update: Actually, taking a couple more minutes looking this morning, http://matrix.cpantesters.org/?dist=Heap-Simple-Perl+0.14 shows that the problem is newer versions of Perl and (as noted in another reply) with unit tests testing fragile things (unit tests being more sensitive to environment changes is another common problem).

Next, since many modules are able to get tests to run fine under Windows, I was curious if the module was doing something unusual or complex in how it arranged for the tests to be run. Looking at Makefile.PL, there was certainly some extra complexity there (at least in part to prompt the user for whether or not they wanted benchmarks to be run). Though, it still looked like it boiled down to a fairly vanilla invocation of ExtUtil::MakeMaker. So it'd take me more time to dive into that complexity to see if I could find a likely source for the failures on Windows, and I had no plans to debug to that level.

Finally, I noticed that the "% pass" value for the module was 100% for several prior versions of the module. So just asking for a slightly older version to be installed would likely make all of the problems go away. And then reading the Changes file showed that those changes were all about how installation was done and not about what the module actually does, so it seemed extremely likely that both new and old versions of the module would work just fine but that slightly old versions of the module would likely install w/o issues.

- tye        


In reply to Re^5: Size-limited, fitness-based lists (reading) by tye
in thread Size-limited, fitness-based lists by AppleFritter

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.