[issue11850] mktime - OverflowError: mktime argument out of range - on very specific time

JoeKuan report at bugs.python.org
Fri Apr 15 13:11:18 CEST 2011


New submission from JoeKuan <kuan.joe at gmail.com>:

>>> a = (1970, 1, 1, 0, 59, 58, 0, 0, 0)
>>> time.mktime(a)
-2.0

>>> a = (1970, 1, 1, 0, 59, 59, 0, 0, 0)
>>> time.mktime(a)
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
OverflowError: mktime argument out of range

>>> a = (1970, 1, 1, 1, 0, 0, 0, 0, 0)
>>> time.mktime(a)
0.0

>>> a = (1970, 1, 1, 0, 59, 60, 0, 0, 0)
>>> time.mktime(a)
0.0

----------
messages: 133806
nosy: JoeKuan
priority: normal
severity: normal
status: open
title: mktime - OverflowError: mktime argument out of range - on very specific time
versions: Python 2.6

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue11850>
_______________________________________


More information about the Python-bugs-list mailing list