Bug#665809: libdate-manip-perl: ParseDate breaks on non-existing times during DST change

Andy Spiegl reportbug.andy at spiegl.de
Mon Apr 2 10:41:35 UTC 2012


Hi Gregor,

thanks for your detailled answer.

> Ah, Date::Manip::Examples is interesting:
Interesting!  I didn't know that.

However, unfortunately this isn't a solution with 6.11-1
because the result of the "parse" function returns "0" in this case.
(using a different invalid date returns "1" as it should)

Try
   print $err, "\n";
in your example:

#v+
#!/usr/bin/perl

use strict; use warnings;

use Date::Manip;

&Date_Init();

#my $functional_date = ParseDate("2012-03-25 at 02:11");

my $oo_date = new Date::Manip::Date;
my $err = $oo_date->parse("2012-03-25 at 02:11");

# should return "1" but v6.11-1 doesn't:
print $err, "\n";
#v-

So, there's no way to check if the date was valid or not.

> So it seems that is a case of finding the nice details and docs, and
> we can close the bug (either unversioned, since the OO interface also
> works in stable, or with 6.30-1, since this contains a fix for the
> functional interface).
I disagree in the case of 6.11-1. :-)

Thanks,
 Andy.

-- 
 lƃǝıds ʎpuɐ
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 190 bytes
Desc: Digital signature
URL: <http://lists.alioth.debian.org/pipermail/pkg-perl-maintainers/attachments/20120402/36e7646b/attachment.pgp>


More information about the pkg-perl-maintainers mailing list