Bug 190849

Summary: versions starting with v or v.
Product: [Fedora] Fedora Reporter: Roy-Magne Mo <rmo>
Component: cpanspecAssignee: Steven Pritchard <steve>
Status: CLOSED UPSTREAM QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: low Docs Contact:
Priority: medium    
Version: 5CC: extras-qa
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
URL: http://search.cpan.org/~kclark/Text-RecordParser-v1.1.2/
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2006-05-05 22:55:32 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
strip leading "v" from rpm version
none
strip leading "v" from rpm version none

Description Roy-Magne Mo 2006-05-05 18:06:13 UTC
Description of problem:
cpanspec parses version numbers starting with 'v' and concludes that this should
be a part of the version number for the rpm packages. This could be both
considered as a bug and a feature :)

Version-Release number of selected component (if applicable):
cpanspec-1.65-1.fc5

How reproducible:
always

Steps to Reproduce:
1.
2.
3.
  
Actual results:


Expected results:


Additional info:

I would like cpanspec to parse the package versions and split of the the first v
or v. from the package - do you agree? 

The package in the URL shows this behaviour.

Comment 1 Steven Pritchard 2006-05-05 21:45:22 UTC
I'd argue that this is a bug in the upstream package, since it is different than
every other package on CPAN that I have looked at.

Looking more closely, there appears to be one package on CPAN that uses "v." in
the file name, and something like 75 that use "V" or "v".

While I'm not crazy about supporting this, it seems to be easy enough.  Try the
attached patch.  It seems obvious enough that I will apply it to the next
release, but I'd appreciate some feedback.

Comment 2 Steven Pritchard 2006-05-05 21:47:03 UTC
Created attachment 128681 [details]
strip leading "v" from rpm version

Comment 3 Steven Pritchard 2006-05-05 21:49:54 UTC
Created attachment 128682 [details]
strip leading "v" from rpm version

Safer regex.

Comment 4 Roy-Magne Mo 2006-05-05 22:38:15 UTC
(In reply to comment #1)
> I'd argue that this is a bug in the upstream package, since it is different than
> every other package on CPAN that I have looked at.
> 
> Looking more closely, there appears to be one package on CPAN that uses "v." in
> the file name, and something like 75 that use "V" or "v".
> 
> While I'm not crazy about supporting this, it seems to be easy enough.  Try the
> attached patch.  It seems obvious enough that I will apply it to the next
> release, but I'd appreciate some feedback.


I completely agree with you that this is a bug in the upstream package, but I
also believe that the time invested in making cpanspec more liberal would be
minimal compared to trying to get all those packages fixed :) 

I tried building one package that shows this problem, works as expected.

This package also has another problem, the $VERSION doesn't get picked up
correctly - but that is a problem of rpm. I registered a bug against it in
rt.cpan.org



Comment 5 Steven Pritchard 2006-05-05 22:55:32 UTC
That sounds like bug 140597.  Does the patch included there fix the problem?

Comment 6 Roy-Magne Mo 2006-05-05 23:30:20 UTC
(In reply to comment #5)
> That sounds like bug 140597.  Does the patch included there fix the problem?

No, this is http://rt.cpan.org/Public/Bug/Display.html?id=19103 - a different
matter. I don't think perl could pick up these things reliably unless it's
starts evaling.