[Python-Dev] test_datetime fails on alpha

Tim Peters tim.one@comcast.net
Wed, 18 Dec 2002 20:04:40 -0500


[Neal Norwitz]
> I used the alpha in the SF compile to verify the bug.  The problem was
> originally reported on the snake-farm from the test suite.
>
> nnorwitz@usf-cf-alpha-linux-1:~/python/dist/src$ ./python
> Python 2.3a0 (#15, Dec 18 2002, 15:52:53)
> [GCC 2.95.4 20011002 (Debian prerelease)] on linux2
> Type "help", "copyright", "credits" or "license" for more information.
> >>> from datetime import timedelta
> >>> timedelta(1, 7, 31)
> datetime.timedelta(1, 7, 31)
> >>> _.days, _.seconds, _.microseconds
> (30064771073, 133143986183, 31)

It's really no help.  The *first* thing to do is to build Python with
optimzation disabled.  Try a debug build, if possible, and step thru
delta_new().  Luckily, that's the hairiest code in the whole module <wink>.

Putting the "wrong parts" in hex, that result is

(0x700000001L, 0x1F00000007L, 31)

which suggests nothing to me.  I don't see any 32-bit assumptions in the
code here, and thanks to two previous lives on 64-bit boxes they usually
punch me in the eyeball if they exist.