Skip Menu |

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the CPAN-Meta CPAN distribution.

Report information
The Basics
Id: 75424
Status: resolved
Priority: 0/
Queue: CPAN-Meta

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

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



Subject: CPAN::Meta::Converter zeroes out version ranges
When using Dist::Zilla it looks as if CPAN::Meta::Converter is used to convert the meta definition in dzil into a valid JSON or YAML file in MetaJSON and MetaYAML. If version ranges (pull 5 in CPAN::Meta on github) are supplied to the converter, it turns them into 0. SPECULATION FOLLOWS: Looks like CPAN::Meta::Converter uses version.pm to validate a version. Things like "== 0.1" get turned into 0 for being invalid. :(
Subject: Re: [rt.cpan.org #75424] CPAN::Meta::Converter zeroes out version ranges
Date: Wed, 29 Feb 2012 11:12:57 -0500
To: bug-CPAN-Meta [...] rt.cpan.org
From: David Golden <dagolden [...] cpan.org>
On Wed, Feb 29, 2012 at 10:24 AM, Cory Watson via RT <bug-CPAN-Meta@rt.cpan.org> wrote: Show quoted text
> When using Dist::Zilla it looks as if CPAN::Meta::Converter is used to convert the meta definition > in dzil into a valid JSON or YAML file in MetaJSON and MetaYAML.  If version ranges (pull 5 in > CPAN::Meta on github) are supplied to the converter, it turns them into 0.
Good catch. I guess version ranges are so rarely used "in the wild" that no one noticed. CPAN::Meta::Converter::_clean_version should either be parsing full version ranges or should be handing off to CPAN::Meta::Requirements to do so (if it can handle malformed ones). -- David
fixed in 2.120620