I vote No on proposed CPANTS metrics

kid51 on 2008-06-09T22:43:19

Gabor Szabo has requested comments on his proposal for addition of new metrics to CPANTS.

I vote No, for most of the same reasons Test::NoWarnings. Its author, Fergal Daly, is one of the sharpest people in the Perl QA world. But Test::Warnings is not part of the Perl core distribution. So to earn this proposed Kwalitee metric, I would have to include Test::NoWarnings underneath the t/ directory in each one of my CPAN distributions. That's pointless.


You're kidding, right?

ferreira on 2008-06-10T13:23:38

I don't have any sympathy for the "uses_test_nowarnings" metric (mainly because it promotes Test::NoWarnings to a universal best practice to be used -- and abused -- everywhere). That happened before with Test::Pod and Test::PodCoverage and their corresponding metrics. On the other hand, to make sure that your code is free from warnings you don't know about is a good idea. But there's code that needs it and others that don't -- just like it happens with "use warnings" or "use strict".

But you're certainly kidding when you said:

So to earn this proposed Kwalitee metric, I would have to include Test::NoWarnings underneath the t/ directory in each one of my CPAN distributions.

Prerequisites (including the one needed for tests, or more generally build) are declared via Makefile.PL/Build.PL with a large array of options to make them optional, recommended, real requirements. The test code may also test for availability of a module and skip the test, like the POD and POD-coverage tests usually do. Adding a fully-fledged CPAN module to t/ to flee from yet another requirement is really a poor alternative. Something better could be done with Module::Install and other similar developer-helper modules (which at least will let you update the embedded dependency at a later date without much suffering).

Re:You're kidding, right?

chromatic on 2008-06-10T22:06:47

Something better could be done with Module::Install and other similar developer-helper modules (which at least will let you update the embedded dependency at a later date without much suffering).

Refusing to add unnecessary complexity which only serves to toggle one bit in a Kwalitee index is a sure sign of Actual Quality. This is one case where Kwalitee is very much at odds with Quality.