This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author akira
Recipients akira, barry, r.david.murray
Date 2014-04-16.20:00:03
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1397678403.49.0.851331817917.issue21267@psf.upfronthosting.co.za>
In-reply-to
Content
>>> from email.utils import mktime_tz, parsedate_tz
>>> mktime_tz(parsedate_tz('Thu, 1 Jan 1970 00:00:00 GMT'))
3600.0

It must returns `0` instead of `3600.0` assuming POSIX timestamp.

UTC offsets in 1970 and today are different from each other by one hour in my local timezone (`time.mktime(1970, ..)` uses one UTC offset and `time.timezone` another). There are around a hundred such timezones.

Note: `time.timezone == time.altzone` in my local timezone i.e., it can't be the documented DST issue.

The bug is present in Python 2.6.9 (the last 2.6 release). 
The bug is present in Python 2.7.3 (Ubuntu 12.04 LTS supported until 2017)

It is fixed in Python 2.7.4+ while replacing `time.mktime` with `calendar.timegm` in issue 14653.
History
Date User Action Args
2014-04-16 20:00:03akirasetrecipients: + akira, barry, r.david.murray
2014-04-16 20:00:03akirasetmessageid: <1397678403.49.0.851331817917.issue21267@psf.upfronthosting.co.za>
2014-04-16 20:00:03akiralinkissue21267 messages
2014-04-16 20:00:03akiracreate