CPAN dependencies and test results checker

brian_d_foy on 2007-08-04T18:08:00

After a discussion on the perl-qa list, and being blessed with a few hours free time, I wrote a shiny thing, which, given a module name on the CPAN, will find all its dependencies, and their dependencies yea even unto the Nth generation, and display a nice shiny report on their CPAN-testers results.

I expect it to be useful for authors trying to decide what to depend on (you don't want to depend on stuff that itself has fragile dependencies) and also for people trying to figger out why the hell some random module won't install.

To see half the CPAN, try pointing it at Angerwhale.


Needs some caching?

Aristotle on 2007-08-04T21:45:48

Any query page is very slow to load, even after querying the same module a second time right away.

Re:Needs some caching?

drhyde on 2007-08-05T08:48:06

Added some caching now, which makes it quite a bit better. It's still slow though, because:

  • It's on the cheapest hosting provider I could find;
  • It uses CGI


It's intended mainly as a proof-of-concept. Hopefully someone will pick it up and integrate it into the cpan-testers site and do all the boring work of making it mod_perl-safe :-)

Very cool

jrockway on 2007-08-05T01:56:06

This is quite helpful. I know Angerwhale is a pain to install, but now I can see that Crypt::OpenPGP is the flakiest module I depend on (and mostly because it depends on other flaky modules).

Crypt::OpenPGP will be optional Real Soon Now.

And BTW, I think Plagger and Jifty both have more dependencies. :)

Re:Very cool

sartak on 2007-08-05T02:24:14

Jifty does have more deps, but I'm not convinced that's a bad thing! :)

Circs

kwilliams on 2007-08-05T03:42:45

That's pretty rad. Is there anything that will detect & show circular dependencies?

 -Ken

some ideas that come to mind

jhi on 2007-08-05T12:49:03

Pretty & cool!

Compute this once per night/weekend for all the modules in the CPAN to draw pretty graphs.

Add an option of ignoring modules that begin with Test:: and are included only because of modules beginning with Test::

Re:some ideas that come to mind

drhyde on 2007-08-06T11:20:26

If I were to pre-compute results, then probably the thing to do is to drive it off the CPAN recent uploads list. I won't ignore Test::* dependencies, because if someone lists one of 'em as a pre-requisite then its failures are just as important as failures in any other dependency. Which, by a rather convoluted route, brings us back to the mailing list thread that spawned this, in which people were grumbling about Test::Pod etc causing failures.

Just as efficient as the module authors...

janus on 2007-08-06T13:39:53

Speaking from a porters point of view i've seen _so_ many modules with wrong and/or hidden dependencies that i hardly believe the results will be satisfactory to all of us.
Even if you just focus on build/run-depends you'll notice many inconsistencies :-/

Sure it's a nice to have - but unfortunately not as reliable as we might hope.

The most effective way... would be correct dependencies or collecting them manually... or better: allow to mark wrong dependencies so we have a way to identify them and file proper bug reports.

Simon

This is marvellous

grinder on 2007-08-07T07:05:40

This is a very nifty thing you have built.

One can look at barbie's statistics on modules that fail http://perl.grango.org/wdists.html and http://perl.grango.org/wpcent.html and then rebound off domm's Kwalitee pages that provides the crucial list of which modules/dists depend on a flakey module.

This would then allow people to hone in on unloved, critical modules and see if the author is no longer interested in them and take over maintenance (or maybe the author doesn't realise these tools exist these days, and it might revive their interest.

But we need to pull all this together and create a one-stop shopping place for all your testing needs.

Mebbe we can figger out how to go about doing this at Y::E this year. We need a plan.

Re:This is marvellous

drhyde on 2007-08-08T09:37:50

Are you signed up for the CPAN Testers BOF?

Re:This is marvellous

grinder on 2007-08-09T08:36:02

Natürlich :)

Net::SSH::Perl FTW!

djberg96 on 2007-08-17T21:55:22

If memory serves, the "record" (in my experience) for most dependencies, when built with ssh1 and ssh2 support and all the optional encryption stuff, was Net::SSH::Perl.

That only shows 18 because it can't figure out all the dependencies. The final tally was over 30, iirc. And that was only if you were lucky enough to get Math::Pari to build.

Update ...

drhyde on 2007-08-20T11:56:04

I've abstracted out the bit that finds dependencies, it's now on the CPAN, as CPAN::FindDependencies. It also installs a 'cpandeps' script.