Skip Menu |

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the DateTime CPAN distribution.

Report information
The Basics
Id: 3303
Status: resolved
Priority: 0/
Queue: DateTime

People
Owner: DROLSKY [...] cpan.org
Requestors: g.picard [...] sheffield.ac.uk
Cc:
AdminCc:

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



Subject: test t20infinite.t failed on Linux mandrake 9.0
The test t/infinite20.t (DateTime-1601 with perl 5.8.0) failed at line 53 and then at line 61 (certainly because of the first failure). I added a debug line after line 53: print STDERR "\nlong_ago=",$long_ago->ymd,"\nneg_dur=",$neg_dur->deltas,"\nneg2=",$neg2->ymd,"\nneg=",$neg->ymd,"\n\n"; and I get the following output: t/20infinite............ok 8/40 long_ago=-100000-01-01 neg_dur=months0days-infminutes0secondsnannanoseconds-inf neg2=-0001--01--01 neg=-2147483648--2147483648--2147483648 There is certainly a misinterpretation of -infinite time, is negative enough or should it be -inf--inf--inf ? Ghislain Picard
Date: Sun, 24 Aug 2003 10:06:58 -0500 (CDT)
From: Dave Rolsky <autarch [...] urth.org>
To: Guest via RT <bug-DateTime [...] rt.cpan.org>
CC: g.picard [...] sheffield.ac.uk, datetime <datetime [...] perl.org>
Subject: Re: [cpan #3303] test t20infinite.t failed on Linux mandrake 9.0
RT-Send-Cc:
[ moved onto the datetime list ] On Thu, 21 Aug 2003, Guest via RT wrote: Show quoted text
> > This message about DateTime was sent to you by guest <> via rt.cpan.org > > Full context and any attached attachments can be found at: > <URL: https://rt.cpan.org/Ticket/Display.html?id=3303 > > > The test t/infinite20.t (DateTime-1601 with perl 5.8.0) failed at line 53 and then at line 61 (certainly because of the first failure). I added a debug line after line 53: > print STDERR "\nlong_ago=",$long_ago->ymd,"\nneg_dur=",$neg_dur->deltas,"\nneg2=",$neg2->ymd,"\nneg=",$neg->ymd,"\n\n"; > > and I get the following output: > > t/20infinite............ok 8/40 > long_ago=-100000-01-01 > neg_dur=months0days-infminutes0secondsnannanoseconds-inf > neg2=-0001--01--01 > neg=-2147483648--2147483648--2147483648 > > > There is certainly a misinterpretation of -infinite time, is negative enough or should it be -inf--inf--inf ?
It should ben -inf for all values. Can you respond with the output of "perl -V"? -dave /*======================= House Absolute Consulting www.houseabsolute.com =======================*/
From: adanx26 [...] yahoo.com
[guest - Thu Aug 21 04:17:22 2003]: Show quoted text
> The test t/infinite20.t (DateTime-1601 with perl 5.8.0) failed at line > 53 and then at line 61 (certainly because of the first failure). I > added a debug line after line 53: > print STDERR "\nlong_ago=",$long_ago->ymd,"\nneg_dur=",$neg_dur-
> >deltas,"\nneg2=",$neg2->ymd,"\nneg=",$neg->ymd,"\n\n";
> > and I get the following output: > > t/20infinite............ok 8/40 > long_ago=-100000-01-01 > neg_dur=months0days-infminutes0secondsnannanoseconds-inf > neg2=-0001--01--01 > neg=-2147483648--2147483648--2147483648 > > > There is certainly a misinterpretation of -infinite time, is negative > enough or should it be -inf--inf--inf ? > > Ghislain Picard
Hmmm. This exact problem is happening to me as well. I have tried on 2 standard RedHat 9.0 installations. Any word on the resolution?
From: adanx26 [...] yahoo.com
[guest - Thu Feb 5 15:27:10 2004]: Show quoted text
> [guest - Thu Aug 21 04:17:22 2003]: >
> > The test t/infinite20.t (DateTime-1601 with perl 5.8.0) failed at line > > 53 and then at line 61 (certainly because of the first failure). I > > added a debug line after line 53: > > print STDERR "\nlong_ago=",$long_ago->ymd,"\nneg_dur=",$neg_dur-
> > >deltas,"\nneg2=",$neg2->ymd,"\nneg=",$neg->ymd,"\n\n";
> > > > and I get the following output: > > > > t/20infinite............ok 8/40 > > long_ago=-100000-01-01 > > neg_dur=months0days-infminutes0secondsnannanoseconds-inf > > neg2=-0001--01--01 > > neg=-2147483648--2147483648--2147483648 > > > > > > There is certainly a misinterpretation of -infinite time, is negative > > enough or should it be -inf--inf--inf ? > > > > Ghislain Picard
> > > Hmmm. This exact problem is happening to me as well. I have tried on 2 > standard RedHat 9.0 installations. Any word on the resolution?
Ignore my statement. I meant this to post on the installation bug; not this one.
t/20infinite.t is failing for me as well. OS X 10.3.9, perl 5.8.6 (from fink). DateTime 0.2901. perl -V attached. ok 16 - infinity - normal duration = infinity not ok 17 - infinity (datetime) == infinity (number) # Failed test 'infinity (datetime) == infinity (number)' # in t/20infinite.t at line 72. # got: '-0001--01--01T-01:-01:-01' # expected: 'inf' not ok 18 - neg infinity (datetime) == neg infinity (number) # Failed test 'neg infinity (datetime) == neg infinity (number)' # in t/20infinite.t at line 75. # got: '-2147483648--2147483648--2147483648T-2147483648:-2147483648:-2147483648' # expected: '-inf' ok 19 - pos year is inf
Download perl_V
application/octet-stream 3.9k

Message body not shown because it is not plain text.

Date: Wed, 10 Aug 2005 13:12:02 -0500 (CDT)
From: Dave Rolsky <autarch [...] urth.org>
To: Michael_G_Schwern via RT <bug-DateTime [...] rt.cpan.org>
Subject: Re: [cpan #3303] test t20infinite.t failed on Linux mandrake 9.0
RT-Send-Cc:
On Wed, 10 Aug 2005, Michael_G_Schwern via RT wrote: Show quoted text
> t/20infinite.t is failing for me as well. OS X 10.3.9, perl 5.8.6 (from > fink). DateTime 0.2901. perl -V attached. > > ok 16 - infinity - normal duration = infinity > not ok 17 - infinity (datetime) == infinity (number) > > # Failed test 'infinity (datetime) == infinity (number)' > # in t/20infinite.t at line 72. > # got: '-0001--01--01T-01:-01:-01' > # expected: 'inf' > not ok 18 - neg infinity (datetime) == neg infinity (number) > > # Failed test 'neg infinity (datetime) == neg infinity (number)' > # in t/20infinite.t at line 75. > # got: > '-2147483648--2147483648--2147483648T-2147483648:-2147483648:-2147483648' > # expected: '-inf' > ok 19 - pos year is inf
This is a known problem. A lot of platforms seem to act weirdly with IEEE infinity and NaN. I've been meaning to replace the use of these with objects that are overloaded to do the right thing. It'll be slower but portable. -dave