Skip Menu |
 

This queue is for tickets about the App-Cpan CPAN distribution.

Report information
The Basics
Id: 93855
Status: open
Priority: 0/
Queue: App-Cpan

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

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

Attachments
App-Cpan-1.5902-increase_cpan-O_precision.patch



Subject: Insufficent precision in "cpan -O" report
Download (untitled) / with headers
text/plain 501b
cpan -O reports the list of locally installed modules out of date. Its output is "module old_version $new_version" but version are truncated 4 digits after the dot. But sometimes, it's not enough to show the version difference. I propose to show 9 digits after the dot, which should be more than enough to cope with traditional perl versioning. Attached patch implements this. Before patch: [...] Data::Section 0.20000 0.20000 [...] After patch: [...] Data::Section 0.200005000 0.200006000 [...]
Subject: App-Cpan-1.5902-increase_cpan-O_precision.patch
--- lib/App/Cpan.pm.orig 2014-03-14 11:39:57.627219844 +0100 +++ lib/App/Cpan.pm 2014-03-14 11:39:15.802990159 +0100 @@ -1175,7 +1175,7 @@ { next unless $module->inst_file; next if $module->uptodate; - printf "%-40s %.4f %.4f\n", + printf "%-40s %.9f %.9f\n", $module->id, $module->inst_version ? $module->inst_version : '', $module->cpan_version;
Download (untitled) / with headers
text/plain 248b
Yeah, this is a problem, but I don't like the idea of also giving more precision to versions which don't have it. We'll need a patch that knows how to treat the actual version and I might have to give up on the idea of lining up the decimal points.
Download (untitled) / with headers
text/plain 438b
On Fri Mar 14 14:08:49 2014, BDFOY wrote: Show quoted text
> Yeah, this is a problem, but I don't like the idea of also giving more > precision to versions which don't have it. We'll need a patch that > knows how to treat the actual version and I might have to give up on > the idea of lining up the decimal points.
Indeed, then should the patch be changed to: - printf "%-40s %.4f %.4f\n", + printf "%-40s %-15s %s\n",


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.