Skip Menu |

This queue is for tickets about the CPANPLUS CPAN distribution.

Report information
The Basics
Id: 13969
Status: resolved
Priority: 0/
Queue: CPANPLUS

People
Owner: Nobody in particular
Requestors: kwilliams [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: CPANPLUS installs without testing
I opened up a CPAN (not CPANPLUS) session and typed "install CPANPLUS" (to start testing out the CPANPLUS::Dist::Build distribution), and received an error message about some "config" version being too low, and then the module happily installed anyway because it told CPAN that all tests were successful: Running make test PERL_DL_NONLAZY=1 /usr/bin/perl "-MExtUtils::Command::MM" "-e" "test_harness(0, 'inc', 'blib/lib', 'blib/arch')" t/00_CPANPLUS-Internals-Utils.t t/00_CPANPLUS-Internals-Utils....[ERROR] Your config is of version '0.0499' but 'CPANPLUS' requires a config of '0.050_04' or higher. Your 'CPANPLUS' is of version '0.055', but your config requires a version of '0' or higher. You will need to reconfigure t/00_CPANPLUS-Internals-Utils....ok All tests successful. To avoid this, when the test bail out, it needs to return the correct status to the caller so the module won't continue getting installed. -Ken
[KWILLIAMS - Mon Aug 1 22:02:09 2005]: Show quoted text
> I opened up a CPAN (not CPANPLUS) session and typed "install CPANPLUS" > (to start testing > out the CPANPLUS::Dist::Build distribution), and received an error > message about some > "config" version being too low, and then the module happily installed > anyway because it told > CPAN that all tests were successful: > > Running make test > PERL_DL_NONLAZY=1 /usr/bin/perl "-MExtUtils::Command::MM" "-e" > "test_harness(0, 'inc', > 'blib/lib', 'blib/arch')" t/00_CPANPLUS-Internals-Utils.t > t/00_CPANPLUS-Internals-Utils....[ERROR] Your config is of version > '0.0499' but 'CPANPLUS' > requires a config of '0.050_04' or higher. Your 'CPANPLUS' is of > version '0.055', but your > config requires a version of '0' or higher. You will need to > reconfigure > t/00_CPANPLUS-Internals-Utils....ok > All tests successful.
The part you're not adding to your report is that you seem to have explicitly told CPANPLUS not to configure itself -- i can tell by the fact it only runs 1 test, which is the basic test if you choose not to configure CPANPLUS. The tests do not fail, as that test does not use the config.pm, but it's implicitly initialized by an include file for the tests, which therefor prints a confusing message to the screen. patch 12136 sees to it that this warning does not occur when running the basic tests on an unconfigured CPANPLUS. Show quoted text
> To avoid this, when the test bail out, it needs to return the correct > status to the caller so the > module won't continue getting installed.
The tests did not actually fail, which can be proven if you run the test file by itself. For clarity's sake -- you will have to configure CPANPLUS before you can use it. The easiest way is to do it at 'perl Makefile.PL' time.
[KANE - Tue Aug 2 03:29:10 2005]: Show quoted text
> The part you're not adding to your report is that you seem to have > explicitly told > CPANPLUS not to configure itself
Right, because I had already just configured it - I went through the whole configuration process, then one test (CPANPLUS::Dist::Build) failed, and then I did "install CPANPLUS" again (to see whether the error changed), thinking it would simply use the configuration I had given it only moments before. Show quoted text
> The tests did not actually fail, which can be proven if you run the > test file by itself.
I know they *didn't* fail, what I'm saying is that they *should* fail, because after this sequence I was left with a fully-installed CPANPLUS that didn't work. If it knows during testing time that the configuration is broken, it shouldn't let CPAN continue installing it. To fix the issue, of course, I did another "force install CPANPLUS" and went through the configuration sequence again. -Ken
From: "Jos I. Boumans" <kane [...] xs4all.net>
Subject: Re: [cpan #13969] CPANPLUS installs without testing
Date: Tue, 2 Aug 2005 15:19:50 +0200
To: bug-CPANPLUS [...] rt.cpan.org
RT-Send-Cc:
On Aug 2, 2005, at 3:15 PM, Ken_Williams via RT wrote: Show quoted text
> > This message about CPANPLUS was sent to you by KWILLIAMS > <KWILLIAMS@cpan.org> via rt.cpan.org > > Full context and any attached attachments can be found at: > <URL: https://rt.cpan.org/Ticket/Display.html?id=13969 > > > [KANE - Tue Aug 2 03:29:10 2005]: >
>> The part you're not adding to your report is that you seem to have >> explicitly told >> CPANPLUS not to configure itself
> > Right, because I had already just configured it - I went through the > whole configuration process, then one test (CPANPLUS::Dist::Build) > failed, and then I did "install CPANPLUS" again > (to see whether the error changed), thinking it would simply use the > configuration I had given it only moments before.
If you still have the log text from that session i'd be interested in it. I'm afraid i can't debug it any further without those diagnostics. Show quoted text
>> The tests did not actually fail, which can be proven if you run the >> test file by itself.
> > I know they *didn't* fail, what I'm saying is that they *should* fail, > because after this sequence I was left with a fully-installed CPANPLUS > that didn't work. If it knows during > testing time that the configuration is broken, it shouldn't let CPAN > continue installing it.
No. The bug is that it printed diagnostic messages in the limited test scenario that it shouldn't (that is fixed) -- it fully intended to run without a config. If you think that is in error (as it should have picked up some other config), then i'd love to see a recreatable test case, or otherwise some terminal scrollback. I'm not sure what happened there. It could be that CPAN.pm tosses out the old extraction dir and re-extracts when you hit 'install' again. That would explain the missing config. -- Jos Boumans "Never ask a man what computer he uses. If it's a Mac, he'll tell you. If it's not, why embarrass him?" - Tom Clancy CPANPLUS http://cpanplus.sf.net
[kane@xs4all.net - Tue Aug 2 09:20:11 2005]: Show quoted text
> > On Aug 2, 2005, at 3:15 PM, Ken_Williams via RT wrote: >
> > I know they *didn't* fail, what I'm saying is that they *should*
> fail,
> > because after this sequence I was left with a fully-installed
> CPANPLUS
> > that didn't work. If it knows during > > testing time that the configuration is broken, it shouldn't let CPAN > > continue installing it.
> > No. The bug is that it printed diagnostic messages in the limited test > scenario > that it shouldn't (that is fixed) -- it fully intended to run without > a config.
That seems even worse - then the module will get fully installed, and be broken, and the user won't have any clue what's wrong. At least in my case I had a clue because I saw the error messages. Why is it desirable behavior to identify a problem that will prevent CPANPLUS from working correctly, then ignore that problem and arrange for none of the tests to fail so that the brokenly-configured module gets installed? Perhaps I don't understand the relationship between the configuration and the code or something. -Ken
From: "Jos I. Boumans" <kane [...] dwim.org>
Subject: Re: [Cpanplus-bugs] [cpan #13969] CPANPLUS installs without testing
Date: Wed, 17 Aug 2005 09:36:40 +0200
To: bug-CPANPLUS [...] rt.cpan.org
RT-Send-Cc:
On Aug 16, 2005, at 3:59 AM, Ken_Williams via RT wrote: Show quoted text
>> No. The bug is that it printed diagnostic messages in the limited test >> scenario that it shouldn't (that is fixed) -- it fully intended to >> run without a config.
> > That seems even worse - then the module will get fully installed, and > be broken, and the > user won't have any clue what's wrong. At least in my case I had a > clue because I saw the > error messages. > > Why is it desirable behavior to identify a problem that will prevent > CPANPLUS from working > correctly, then ignore that problem and arrange for none of the tests > to fail so that the > brokenly-configured module gets installed? Perhaps I don't understand > the relationship > between the configuration and the code or something.
Several people have pointed out that the person installing CPANPLUS often isn't the one running CPANPLUS. The one who runs it wants to configure it, the person who installs it doesn't. So, it's possible to install without a complete config.pm and have users later create their own (which they can put in non-system directories). -- Jos Boumans How do I prove I am not crazy to people who are? CPANPLUS http://cpanplus.sf.net