What should be in a README anyway (was Re: Phalanx / CPANTS / Kwalitee)

2003-10-15 Thread Richard Clamp
On Tue, Oct 14, 2003 at 01:14:44PM -0700, Randal L. Schwartz wrote:
> Of course, if you have a well-written name/synopsis/author info,
> I guess this is enough.  But now we've just shifted the problem.

Well when I initially thought about it I was answering the needs of
someone who wanted to know: what the module does, what its api looks
like, and what else is it going to want me to install.

If there are other more tangible needs for a README that contribute to
the magical "makes me want to untar it" factor then I'd like to
accommodate them but first I'll need to know what they are.  Can you
offer pointers?

-- 
Richard Clamp <[EMAIL PROTECTED]>


Re: Phalanx / CPANTS / Kwalitee

2003-10-15 Thread Thomas Klausner
Hi!

On Mon, Oct 13, 2003 at 02:57:34AM -0700, Michael G Schwern wrote:
> On Mon, Oct 13, 2003 at 10:28:29AM +0200, Thomas Klausner wrote:
> > * contains files:
> >   * Makefile.PL or Build.PL or configure
> 
> configure?

there are currently 4 dists on CPAN that only include a configure script 
(makepp-1.19, glist-0.9.17a10, swig1.1p5, shufflestat-0.0.3)

179 do not include any of Makefile.PL, Build.PL or configure.

Quite a lot come with two or three of those files.

But IMO a 'configure' is not a proper subsitute for Makefile.PL/Build.PL, so
I won't use it as a kwalitee indicator.


> >   * t/* or test.pl
> 
> test.pl is not a good thing.  It doesn't get parsed by "make test".  It just
> runs and spits the output to the screen.  If a test fails, "make test" will
> still succeed.  Still, its better than nothing at all.

So t/* should hint more kwalitee than only test.pl

> > Some ideas:
> > * wheater PREREQ_PM matches used modules (hard!)
> 
> Nearly impossible since:
> 
> require Foo::Bar if $some_condition;

There are obvioulsy edge cases, but one can detect the most plain
use/require statements.

> Otherwise Module::Info->modules_used() can handle it.

modules_used needs to compile the module, so it cannot be used for CPANTS.

-- 
#!/usr/bin/perl   http://domm.zsi.at
for(ref bless{},just'another'perl'hacker){s-:+-$"-g&&print$_.$/}


Re: Phalanx / CPANTS / Kwalitee

2003-10-15 Thread Thomas Klausner
Hi!

On Mon, Oct 13, 2003 at 07:46:02PM +0200, Tels wrote:

> > * POD/Code ratio (what would be a good measurement?)
> 
> No. Some _very_ complex code takes little documentation like:

Agreed.


> Probably something like:
> 
>   *.pm file has more than 1000 lines of code => bad
> 
> :-)

CPANTS does/will count lines of code (and POD). While those numbers probably
won't go into a kwalitee rating (while it still might be an interesting
metric, so I'm not sure..), anybody can grab them and do their own weighting.
("I /only/ use modules with less than 1000 lines of code. Everything longer
must be crap...")

-- 
#!/usr/bin/perl   http://domm.zsi.at
for(ref bless{},just'another'perl'hacker){s-:+-$"-g&&print$_.$/}


Re: Phalanx / CPANTS / Kwalitee

2003-10-15 Thread Thomas Klausner
Hi!

On Mon, Oct 13, 2003 at 05:53:15PM -, Rafael Garcia-Suarez wrote:

> > * POD/Code ratio (what would be a good measurement?)
> 
> use Pod::Coverage ?

As far as I know, Pod::Coverage compiles the module, which makes it not
suitable for CPANTS.

OTOH, it might be an interesting idea to allow CPANTS to compile code (and
thus use stuff like Devel::Cover) if not testing the whole of CPAN, but
"linting" one distribution.


-- 
#!/usr/bin/perl   http://domm.zsi.at
for(ref bless{},just'another'perl'hacker){s-:+-$"-g&&print$_.$/}


Re: Phalanx / CPANTS / Kwalitee

2003-10-15 Thread Rafael Garcia-Suarez
Thomas Klausner wrote:
> there are currently 4 dists on CPAN that only include a configure script 
> (makepp-1.19, glist-0.9.17a10, swig1.1p5, shufflestat-0.0.3)
> 
> 179 do not include any of Makefile.PL, Build.PL or configure.
> 
> Quite a lot come with two or three of those files.

Could we infer that a distribution that comes with several Makefile.PLs
may have an overcomplicated build process, maybe indicating a low
kwalitee ?

See for example :
http://search.cpan.org/~msergeant/XML-Parser-2.34/MANIFEST


Re: Phalanx / CPANTS / Kwalitee

2003-10-15 Thread Richard Clamp
On Wed, Oct 15, 2003 at 12:03:58PM +0200, Thomas Klausner wrote:
> On Mon, Oct 13, 2003 at 05:53:15PM -, Rafael Garcia-Suarez wrote:
> > use Pod::Coverage ?
> 
> As far as I know, Pod::Coverage compiles the module, which makes it not
> suitable for CPANTS.

Afraid so.  It's an eventual TODO-list item to steal/use the PPI
parser from Claes' CPANXR rather than compiling the code.  The
compilation is there to answer the question "what methods does package
X define".

-- 
Richard Clamp <[EMAIL PROTECTED]>


Re: Phalanx / CPANTS / Kwalitee

2003-10-15 Thread Nick Ing-Simmons
Rafael Garcia-Suarez <[EMAIL PROTECTED]> writes:
>Thomas Klausner wrote:
>> there are currently 4 dists on CPAN that only include a configure script 
>> (makepp-1.19, glist-0.9.17a10, swig1.1p5, shufflestat-0.0.3)
>> 
>> 179 do not include any of Makefile.PL, Build.PL or configure.
>> 
>> Quite a lot come with two or three of those files.
>
>Could we infer that a distribution that comes with several Makefile.PLs
>may have an overcomplicated build process, maybe indicating a low
>kwalitee ?

Should I infer that to get Tk's kwalitee up it should build as a 
one monolithic .so ?

>
>See for example :
>http://search.cpan.org/~msergeant/XML-Parser-2.34/MANIFEST



Re: Phalanx / CPANTS / Kwalitee

2003-10-15 Thread Rafael Garcia-Suarez
Nick Ing-Simmons <[EMAIL PROTECTED]> wrote:
> >Could we infer that a distribution that comes with several Makefile.PLs
> >may have an overcomplicated build process, maybe indicating a low
> >kwalitee ?
> 
> Should I infer that to get Tk's kwalitee up it should build as a 
> one monolithic .so ?

I don't know, I'm asking.
So it's necessary to have one separate Makefile.PL by .so built ?


Re: Phalanx / CPANTS / Kwalitee

2003-10-15 Thread Adrian Howard
On Wednesday, Oct 15, 2003, at 11:09 Europe/London, Rafael 
Garcia-Suarez wrote:

Thomas Klausner wrote:
there are currently 4 dists on CPAN that only include a configure 
script
(makepp-1.19, glist-0.9.17a10, swig1.1p5, shufflestat-0.0.3)

179 do not include any of Makefile.PL, Build.PL or configure.

Quite a lot come with two or three of those files.
Could we infer that a distribution that comes with several Makefile.PLs
may have an overcomplicated build process, maybe indicating a low
kwalitee ?
I don't think so.

For example I'm planning to release my modules with Build.PL and 
Makefile.PL in the future (because I like Module::Build, but want to 
continue to support people using CPAN).

(maybe more than one == higher kwalitee :-)

Adrian



Re: Phalanx / CPANTS / Kwalitee

2003-10-15 Thread Leon Brocard
Thomas Klausner sent the following bits through the ether:

> OTOH, it might be an interesting idea to allow CPANTS to compile code (and
> thus use stuff like Devel::Cover) if not testing the whole of CPAN, but
> "linting" one distribution.

Yes. We've been thinking about this. It either needs stealing buildd
from Debian, having a box we don't mind destroying every so often, or
having a VMware virtual machine we can undo easily. What we need is
more free time ;-)

Leon
-- 
Leon Brocard.http://www.astray.com/
scribot.http://www.scribot.com/

... Ethernet: A device for catching the Ether Bunny


Re: Phalanx / CPANTS / Kwalitee

2003-10-15 Thread Nick Ing-Simmons
Rafael Garcia-Suarez <[EMAIL PROTECTED]> writes:
>Nick Ing-Simmons <[EMAIL PROTECTED]> wrote:
>> >Could we infer that a distribution that comes with several Makefile.PLs
>> >may have an overcomplicated build process, maybe indicating a low
>> >kwalitee ?
>> 
>> Should I infer that to get Tk's kwalitee up it should build as a 
>> one monolithic .so ?
>
>I don't know, I'm asking.
>So it's necessary to have one separate Makefile.PL by .so built ?

As it stands it needs even more rule-overriding hackery than Tk already 
does to build multiple .so/.dll per/Makefile.

This by the way is the main reason I haven't yet done a Build.PL for Tk - 
I haven't figured out how to "build" sub-modules.




Re: Phalanx / CPANTS / Kwalitee

2003-10-15 Thread Tim Bunce
On Wed, Oct 15, 2003 at 02:10:46PM +0200, Rafael Garcia-Suarez wrote:
> Nick Ing-Simmons <[EMAIL PROTECTED]> wrote:
> > >Could we infer that a distribution that comes with several Makefile.PLs
> > >may have an overcomplicated build process, maybe indicating a low
> > >kwalitee ?
> > 
> > Should I infer that to get Tk's kwalitee up it should build as a 
> > one monolithic .so ?
> 
> I don't know, I'm asking.
> So it's necessary to have one separate Makefile.PL by .so built ?

I don't think you can or should try to infer anything useful from
the number of Makefile.PL's.

Tim.


Re: Phalanx / CPANTS / Kwalitee

2003-10-15 Thread Thomas Klausner
Hi!

On Wed, Oct 15, 2003 at 03:24:22PM +0100, Leon Brocard wrote:
> Thomas Klausner sent the following bits through the ether:
> 
> > OTOH, it might be an interesting idea to allow CPANTS to compile code (and
> > thus use stuff like Devel::Cover) if not testing the whole of CPAN, but
> > "linting" one distribution.
> 
> Yes. We've been thinking about this. It either needs stealing buildd
> from Debian, having a box we don't mind destroying every so often, or

I see the biggest concern not so much with security / conflicting modules,
but with modules that interface to third party code and thus need it
installed (DBD::*, ImageMagick, GD, ...)

Or is some build tool able to automatically fetch needed non-perl libs?

-- 
#!/usr/bin/perl   http://domm.zsi.at
for(ref bless{},just'another'perl'hacker){s-:+-$"-g&&print$_.$/}


Re: Phalanx / CPANTS / Kwalitee

2003-10-15 Thread Michael G Schwern
On Wed, Oct 15, 2003 at 12:09:05PM +0200, Rafael Garcia-Suarez wrote:
> Thomas Klausner wrote:
> > there are currently 4 dists on CPAN that only include a configure script 
> > (makepp-1.19, glist-0.9.17a10, swig1.1p5, shufflestat-0.0.3)
> > 
> > 179 do not include any of Makefile.PL, Build.PL or configure.
> > 
> > Quite a lot come with two or three of those files.
> 
> Could we infer that a distribution that comes with several Makefile.PLs
> may have an overcomplicated build process, maybe indicating a low
> kwalitee ?

No, there's nothing wrong with having sub-build directories.


-- 
Michael G Schwern[EMAIL PROTECTED]  http://www.pobox.com/~schwern/
Kindly do not attempt to cloud the issue with facts.


Re: Phalanx / CPANTS / Kwalitee

2003-10-15 Thread Michael G Schwern
On Wed, Oct 15, 2003 at 11:53:45AM +0200, Thomas Klausner wrote:
> > configure?
> 
> there are currently 4 dists on CPAN that only include a configure script 
> (makepp-1.19, glist-0.9.17a10, swig1.1p5, shufflestat-0.0.3)

configure's an alien idiom on CPAN.  If its found, I think it should be
evaluated on a case-by-case basis.

For example, looking at the above, makepp looks like its trying to emulate
autoconf (sensible, I guess, since he's shipping a make replacement) and its 
doing it the right way.  configure is a wrapper around a perl script that 
spits out a Makefile.  Unfortunately, he shipped the generated Makefile.
Still, it would have been better if configure was a wrapper around a
Build.PL or Makefile.PL.  Its been uploaded in the last few months.

glist, OTOH, is shipping a configure written in shell.  Sorta silly.  He also 
shipped generated configure files that shouldn't be shipped (like 
config.cache).  Since the dist is pure Perl, the guy is probably just 
comfortable with the configure/shell layout.  It was touched last year.

swig is a C program using autoconf, so that seems legit.  It hasn't been
touched since 1998.  There's newer versions of Swig out there.  It should
probably be taken down.

shufflestat is using what looks like a shell autoconf for a pure Perl
program.  Again, sorta silly.  Its also shipping CVS directories and
directories that would have been empty were it not for the empty CVS
directory in it. :)


This all suggests another check: stray files.  Emacs backup files.  CVS
directories.  Empty directories.  #...# backup files.  Makefiles shipped
with Makefile.PL, Build and _build shipped with Build.PL, blib/...


> > test.pl is not a good thing.  It doesn't get parsed by "make test".  It just
> > runs and spits the output to the screen.  If a test fails, "make test" will
> > still succeed.  Still, its better than nothing at all.
> 
> So t/* should hint more kwalitee than only test.pl

Yes.


-- 
Michael G Schwern[EMAIL PROTECTED]  http://www.pobox.com/~schwern/
Death follows me like a wee followey thing.
-- Quakeman


Re: Phalanx / CPANTS / Kwalitee

2003-10-15 Thread Rafael Garcia-Suarez
Michael G Schwern wrote in perl.qa :
> This all suggests another check: stray files.  Emacs backup files.  CVS
> directories.  Empty directories.  #...# backup files.  Makefiles shipped
> with Makefile.PL, Build and _build shipped with Build.PL, blib/...

In other words, the contents of the default MANIFEST.SKIP.


Re: Phalanx / CPANTS / Kwalitee

2003-10-15 Thread Michael G Schwern
On Wed, Oct 15, 2003 at 10:34:19PM -, Rafael Garcia-Suarez wrote:
> Michael G Schwern wrote in perl.qa :
> > This all suggests another check: stray files.  Emacs backup files.  CVS
> > directories.  Empty directories.  #...# backup files.  Makefiles shipped
> > with Makefile.PL, Build and _build shipped with Build.PL, blib/...
> 
> In other words, the contents of the default MANIFEST.SKIP.

Hey, yeah!


-- 
Michael G Schwern[EMAIL PROTECTED]  http://www.pobox.com/~schwern/
WOOHOO!  I'm going to Disneyland!
http://www.goats.com/archive/980805.html


Re: Phalanx / CPANTS / Kwalitee

2003-10-15 Thread Robert Spier
> Yes. We've been thinking about this. It either needs stealing buildd
> from Debian, having a box we don't mind destroying every so often, or
> having a VMware virtual machine we can undo easily. What we need is
> more free time ;-)
> 

User Mode Linux (limiting to Linux, of course) might be a lighter
weight way to do this.

-R