Bug 1653340
Summary: | glibc: mktime fails with tm_isdst == 1 for time zones which never have DST | ||
---|---|---|---|
Product: | [Fedora] Fedora | Reporter: | Miro Hrončok <mhroncok> |
Component: | glibc | Assignee: | Carlos O'Donell <codonell> |
Status: | CLOSED NOTABUG | QA Contact: | Fedora Extras Quality Assurance <extras-qa> |
Severity: | unspecified | Docs Contact: | |
Priority: | unspecified | ||
Version: | rawhide | CC: | aoliva, arjun.is, codonell, dj, fweimer, law, mfabian, osmith, pfrankli, python-maint, rth, siddhesh, vstinner |
Target Milestone: | --- | ||
Target Release: | --- | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | If docs needed, set a value | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2019-06-04 11:06:42 UTC | Type: | Bug |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: | |||
Bug Depends On: | |||
Bug Blocks: | 1652843 |
Description
Miro Hrončok
2018-11-26 15:19:57 UTC
Context: test_email of Python 3.7.1 started to fail on Fedora Rawhide. I reported the bug upstream: https://bugs.python.org/issue35317 (In reply to Miro Hrončok from comment #0) > info.tm_isdst = 1; > $ TZ=CET ./a.out > Mon Mar 12 00:01:00 2012 > $ TZ=CEST ./a.out > Error: unable to make time using mktime: Value too large for defined data > type > $ TZ=UTC ./a.out > Error: unable to make time using mktime: Value too large for defined data > type The behavior is at least inconsistent because there is no DST in effect at this time in all three cases, so tm_isdst == 1 is invalid input. I'm not sure that it's a bug. mktime() fails with TZ=UTC on the same date on FreeBSD since 2012 (FreeBSD 8.2, I can reproduce the bug on FreeBSD 12.0-RC2): https://bugs.python.org/issue35317#msg330443 Moreover, I proposed a fix for test_email of Python: https://github.com/python/cpython/pull/10721 (In reply to Florian Weimer from comment #2) > (In reply to Miro Hrončok from comment #0) > > info.tm_isdst = 1; > > > $ TZ=CET ./a.out > > Mon Mar 12 00:01:00 2012 > > $ TZ=CEST ./a.out > > Error: unable to make time using mktime: Value too large for defined data > > type > > $ TZ=UTC ./a.out > > Error: unable to make time using mktime: Value too large for defined data > > type > > The behavior is at least inconsistent because there is no DST in effect at > this time in all three cases, so tm_isdst == 1 is invalid input. CEST is with DST. The S stands for Summer as in daylight saving. (In reply to Miro Hrončok from comment #4) > (In reply to Florian Weimer from comment #2) > > (In reply to Miro Hrončok from comment #0) > > > info.tm_isdst = 1; > > > > > $ TZ=CET ./a.out > > > Mon Mar 12 00:01:00 2012 > > > $ TZ=CEST ./a.out > > > Error: unable to make time using mktime: Value too large for defined data > > > type > > > $ TZ=UTC ./a.out > > > Error: unable to make time using mktime: Value too large for defined data > > > type > > > > The behavior is at least inconsistent because there is no DST in effect at > > this time in all three cases, so tm_isdst == 1 is invalid input. > > CEST is with DST. The S stands for Summer as in daylight saving. Ah, that explains it. CEST is actually an alias for UTC. CEST is UTC+2. (In reply to Miro Hrončok from comment #6) > CEST is UTC+2. No, CEST is an alias for UTC as far as the time zone database is concerned. Time zone names actually look like Europe/Berlin. The abbreviations are not unique and usually do not work at all. > The abbreviations are not unique and usually do not work at all.
Oh, OK. Sorry.
We also ran into this problem, so I've reported it upstream: https://sourceware.org/bugzilla/show_bug.cgi?id=24630 Upstream indicated that the behavior with UTC and tm_isdst == 1 is expected. |