[Chicago] OverflowError: days=1002410023; must have magnitude <= 999999999
allan2600 at gmail.com
Wed May 20 20:14:55 CEST 2009
Actually, the maximum positive 32-bit integer is 2147483647 (see an example
for calculating that here:
http://www.velocityreviews.com/forums/t366257-range-of-int-type.html), and I
believe that all numbers are signed regardless of size.
I had to do a lot of date calculation and find mxDateTime to be a wonderful
library for calculating dates and elapsed days from a certain date:
http://www.egenix.com/products/python/mxBase/mxDateTime/. One downside is
that this module is based on C libraries, so moving to another platform
might require some compiling (Windows binaries are provided).
On Wed, May 20, 2009 at 1:05 PM, Lukasz Szybalski <szybalski at gmail.com>wrote:
> Anybody knows how to overcome this error?
> I have transactions that have effective and expiration dates and I
> need to calculate how many days are within each transaction(2 million
> transactions) and provide a total numbers of days for that particular
> There seem to be a limit of # -999999999 <= days <= 999999999
> I'm not sure why ?
> If 2147483648 is the 32 bit integer limit then I should have a long way to
> Is this a bug in the library?
> How to create python package?
> Chicago mailing list
> Chicago at python.org
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Chicago