Skip Menu |

This queue is for tickets about the version CPAN distribution.

Report information
The Basics
Id: 70260
Status: resolved
Priority: 0/
Queue: version

People
Owner: Nobody in particular
Requestors: xiong [...] cpan.org (daily)
Cc: andreas.koenig.7os6VVqR [...] franz.ak.mind.de
deqh77wced [...] snkmail.com
walde.christian [...] googlemail.com
AdminCc:

Bug Information
Severity: (no value)
Broken in:
  • 0.85
  • 0.88
Fixed in: (no value)



CC: andreas.koenig.7os6vvqr [...] franz.ak.mind.de, walde.christian [...] googlemail.com, deqh77wced [...] snkmail.com
Subject: smoke fails - can't find vms.pm
Hi John, I'm getting smoke testing failures for my module Devel::Comments v1.1.4 and also previous versions. The issue is of some long standing. These failures occur on a wide variety of platforms (various OS and perl version) and have in common the following: Output from './Build test': Can't locate version/vxs.pm in @INC... In Devel/Comments.pm I have: use version 0.77; our $VERSION = qv('1.1.4'); In Build.PL I have: ... requires => { 'perl' => 5.008, 'version' => 0.77, ... The failing platforms do all have version.pm installed and later than 0.77 but this issue is not limited to a single version of version.pm. Here are some failures: www.cpantesters.org/cpan/report/d153493c-f0e7-11df-8240-cf560c7e6507 www.cpantesters.org/cpan/report/5f5029e2-6c00-1014-869a-80123373d4b5 www.cpantesters.org/cpan/report/12b50e89-6d10-1014-a9d8-8c82000ca92b www.cpantesters.org/cpan/report/5f5029e2-6c00-1014-869a-80123373d4b5 www.cpantesters.org/cpan/report/3fe12eca-c403-11e0-a7c7-dcf97c7f1e01 I don't consider this an "all your problem" by any means. Maybe these smoke testing platforms are flawed. Or I may be doing wrong. I think I should alter my Build.PL file so as to catch these cases and fail in the building, not in later testing. I consider my module's failure to fail well a bug in itself. I don't see that I should build-requires version/vxs.pm but I don't see an alternative, either. I'd appreciate any suggestions you can make here. Thank you, Xiong Changnian
Subject: Re: [rt.cpan.org #70260] smoke fails - can't find vms.pm
Date: Sun, 14 Aug 2011 10:15:09 -0400
To: bug-version [...] rt.cpan.org
From: John Peacock <john.peacock [...] havurah-software.org>
On 08/14/2011 06:37 AM, Xiong Changnian via RT wrote: Show quoted text
> In Devel/Comments.pm I have: > > use version 0.77; our $VERSION = qv('1.1.4');
I would actually not include the specific version on the "use" line, because you have already specified the required minimum release in Build.PL. The reason for this is that it is possible for someone to have to different releases of version.pm installed (the one that came with the Perl and a later CPAN release). That isn't the case here, as near as I can tell. The only time I can think that you would definitely want to have the specific version on the "use" line is if you are requiring something above what would normally be available. Show quoted text
> In Build.PL I have: > > ... > requires => { > 'perl' => 5.008, > 'version' => 0.77,
I would also suggest requiring a later release of version.pm, namely 0.89 or later (0.93 is current). There were some behavioral changes to match core Perl code and the pure Perl version.pm code was completely rewritten in 0.81. Show quoted text
> The failing platforms do all have version.pm installed and later than > 0.77 but this issue is not limited to a single version of version.pm. > Here are some failures:
The really interesting thing is that all of those test failures are under Perl 5.12.x with either 0.85 or 0.88 (5.12.x shipped with version 0.82). What isn't immediately obvious is whether these smokers are running the pure Perl or the XS code from CPAN. I am suspicious of the error message they got, since that kind of implies some sort of packaging mismatch. I'm installing 5.12.4 and I'll try and recreate the test failures. John
Hi John, POD for the current version.pm 0.93 still suggests: use version 0.77; our $VERSION = qv("v1.2.3"); # shorthand I've been warned that version number parsing can be tricky. Perhaps I should write a set of dummy modules with differing declarations and see which ones smoke. On 2011-08-14 12:58:22, john.peacock@havurah-software.org wrote: Show quoted text
> ... it is possible for someone to have [two] different releases > of version.pm installed...
So it is. So, if I only insist on 0.77 in Build.PL, it's not clear to me that when a script actually executes, the right version.pm will be loaded? Show quoted text
> I would also suggest requiring a later release of version.pm...
Yes but: Devel::Comments is based on Smart::Comments; the latter has minimal prerequisites and is expected to run on perl as low as 5.8; also I have promised full backward compatibility through D::C 1.x.x. This may, of course, just be another incentive to roll to D::C 2.0.0. Show quoted text
> I am suspicious of the error message they got...
I, too. My philosophy, though, is that my module should not FAIL smoke test *ever*. If it must fail, let it fail in the build and report NA. So if the smoke platform is somehow ill-built, I want to catch that in the build. As a second choice, I want to be able to state definitely that the platform that's trying to install is faulty; write a test for that, run this test early in my suite, and bailout with an appropriate message. Where I get stuck is that I don't *expect* to see version/vms.pm in @INC. There's none on my platform, in either the system perl or my development interpreter. I don't see how I can require it or test for it without causing the build or test to fail on every platform except these outliers. I await your testing with interest. Thank you, Xiong Changnian
Hi John, I may have a clue about what's causing these failures. I was working on a (completely unrelated) new project and I thought, Well, I'll 'use' a newer version of version.pm; and found out I didn't have that installed. So, I used the 'cpan' script to 'upgrade version'. Now, here is the peculiar thing. 'r version' said that I had 0.80 installed, 0.94 latest. Then upgrade went okay. But after it was done, 'r version' made the same exact report; and my new project script still failed: version version 0.89 required--this is only version 0.8 at... Forcing didn't fix this. I searched through lib/ and found *3* different versions of version.pm in various subfolders. I threw them all out, installed, and now my script is fine and cpan reports that version is up to date. I'm theorizing that if the upgrade process is not going well, some users may have stuff scattered around @INC and so perl interpreter gets confused which to load. What do you say? Thanks, Xiong Changnian
Subject: Re: [rt.cpan.org #70260] smoke fails - can't find vms.pm
Date: Sun, 21 Aug 2011 06:10:35 -0400
To: bug-version [...] rt.cpan.org
From: John Peacock <john.peacock [...] havurah-software.org>
On 08/15/2011 03:16 PM, Xiong Changnian via RT wrote: Show quoted text
> Forcing didn't fix this. I searched through lib/ and found *3* different > versions of version.pm in various subfolders. I threw them all out, > installed, and now my script is fine and cpan reports that version is up > to date.
Prior to version 0.83, the files were installed into the wrong path (site instead of system). So this would explain why you found multiple files; I'll have to add something to the Makefile to probe for those files and delete then on upgrade. Show quoted text
> I'm theorizing that if the upgrade process is not going well, some users > may have stuff scattered around @INC and so perl interpreter gets > confused which to load.
It is simpler than that; I have reproduced the issue and it is caused completely by someone installing the pure Perl release from CPAN on top of a Perl which already includes version.pm in the core: $ ./Build test t/00-load-or-bail.t ............ Can't locate version/vxs.pm in @INC (@INC contains: lib ../lib ../../lib /home/jpeacock/perl5/perlbrew/temp/Devel-Comments-v1.1.4/blib/lib /home/jpeacock/perl5/perlbrew/temp/Devel-Comments-v1.1.4/blib/arch /home/jpeacock/perl5/perlbrew/perls/perl-5.12.4/lib/site_perl/5.12.4/i686-linux /home/jpeacock/perl5/perlbrew/perls/perl-5.12.4/lib/site_perl/5.12.4 /home/jpeacock/perl5/perlbrew/perls/perl-5.12.4/lib/5.12.4/i686-linux /home/jpeacock/perl5/perlbrew/perls/perl-5.12.4/lib/5.12.4 .) at (eval 4) line 2. Now that I have reproduced it, I can look towards fixing it... John
Subject: Re: [rt.cpan.org #70260] smoke fails - can't find vms.pm
Date: Sun, 21 Aug 2011 07:04:07 -0400
To: bug-version [...] rt.cpan.org
From: John Peacock <john.peacock [...] havurah-software.org>
On 08/21/2011 06:10 AM, John Peacock via RT wrote: Show quoted text
> Now that I have reproduced it, I can look towards fixing it...
I've sussed it out; it had to do with the $SIG{__DIE__} handler in your test file. I've protected the use of eval in the version.pm loader and confirmed (with a test) that this fixes the problem. The next time you do a release, you should have use version 0.94; in your code, to pick up the fixed code. I will release that to CPAN shortly... John
Fixed in 0.94 (on CPAN soon)