Skip Menu |

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the DateTime-Format-Strptime CPAN distribution.

Report information
The Basics
Id: 71886
Status: resolved
Priority: 0/
Queue: DateTime-Format-Strptime

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

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



Subject: there does not seem to be a way to format months with a leading zero
When doing `$Strp->format_datetime($dt);` one can print the month number by using the %m format, however that prints only the integer itself. Other strptime implementations include %L for months with leading zeros, but those one does not seem to have that option.
This module just does formatting by calling the DateTime class's - Show quoted text
>strftime method.
I suggest taking a look at DateTime->format_cldr if you need other options. It has a lot more knobs to tweak.
Oh, huh. I never looked at the internals. However I'd still say this report has merit, just so strftime has compatibility to the C strftime implementations. Looking at DateTime.pm that seems rather trivial to patch in too. Should i just make a patch and open a ticket on DateTime?
On Sun Jul 01 18:01:56 2012, MITHALDU wrote: Show quoted text
> Oh, huh. I never looked at the internals. However I'd still say this > report has merit, just so strftime has compatibility to the C strftime > implementations. Looking at DateTime.pm that seems rather trivial to > patch in too. Should i just make a patch and open a ticket on
DateTime? My strftime (Ubuntu 12.04) has no %L, so I don't know how standard this is. The problem with patching DateTime is that I really want DateTime and DT-F-Strptime to be in sync, which means also patching DT-F-Strptime at the same time. Also, I'm just not that keen on adding more strftime stuff. It's a pretty limiting format. CLDR is the way forward. It has a lot more flexibility.
Alright. In that case this discussion is here to document the decision and i'm fine with that. Thanks for pointing out CLDR! :)