Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 190221 - dev-lang/python fails tests with TAI timezone
Summary: dev-lang/python fails tests with TAI timezone
Status: RESOLVED OBSOLETE
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Development (show other bugs)
Hardware: All Linux
: High minor (vote)
Assignee: Python Gentoo Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-08-25 20:07 UTC by Rickard Närström
Modified: 2015-09-14 07:06 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Rickard Närström 2007-08-25 20:07:19 UTC
+++ This is the same problem as described in bug #124188 +++

After changing to a UTC timezone all test succeeds.

(I haven't runed test ignored by the ebuild.)

----
======================================================================
FAIL: test_http2time (test.test_cookielib.DateTimeTests)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/var/tmp/paludis/dev-lang/python-2.5.1-r2/work/Python-2.5.1/Lib/test/test_cookielib.py", line 33, in test_http2time
    self.assertEquals(parse_date("01 Jan 2001"), (2001, 1, 1, 0, 0, 0.0))
AssertionError: (2000, 12, 31, 23, 59, 38) != (2001, 1, 1, 0, 0, 0.0)

======================================================================
FAIL: test_http2time_formats (test.test_cookielib.DateTimeTests)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/var/tmp/paludis/dev-lang/python-2.5.1-r2/work/Python-2.5.1/Lib/test/test_cookielib.py", line 70, in test_http2time_formats
    "%s  =>  '%s' (%s)" % (test_t, result, expected))
AssertionError: 760233600  =>  '1994-02-02 23:59:42Z' (1994-02-03 00:00:00Z)

======================================================================
FAIL: test_time2isoz (test.test_cookielib.DateTimeTests)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/var/tmp/paludis/dev-lang/python-2.5.1-r2/work/Python-2.5.1/Lib/test/test_cookielib.py", line 16, in test_time2isoz
    self.assertEquals(time2isoz(base), "2002-04-19 14:36:40Z")
AssertionError: '2002-04-19 14:36:18Z' != '2002-04-19 14:36:40Z'

======================================================================
FAIL: test_rejection (test.test_cookielib.LWPCookieTests)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/var/tmp/paludis/dev-lang/python-2.5.1-r2/work/Python-2.5.1/Lib/test/test_cookielib.py", line 1521, in test_rejection
    self.assertEquals(old, repr(c))
AssertionError: '<_LWPCookieJar.LWPCookieJar[Cookie(version=1, name=\'wow\', value=\'flutter\', port=None, port_specified=False, domain=\'.a.acme.com\', domain_specified=True, domain_initial_dot=True, path=\'/\', path_specified=False, secure=False, expires=None, discard=True, comment=None, comment_url=None, rest={}, rfc2109=False), Cookie(version=1, name=\'ping\', value=\'pong\', port=None, port_specified=False, domain=\'.acme.com\', domain_specified=True, domain_initial_dot=False, path=\'/\', path_specified=False, secure=False, expires=None, discard=True, comment=None, comment_url=None, rest={}, rfc2109=False), Cookie(version=1, name=\'bang\', value=\'wallop\', port=\'90,100,80,8080\', port_specified=True, domain=\'.sol.no\', domain_specified=True, domain_initial_dot=True, path=\'/\', path_specified=False, secure=False, expires=1188067845, discard=False, comment=\'Just kidding! ("|\\\\\\\\) \', comment_url=None, rest={}, rfc2109=False), Cookie(version=1, name=\'foo9\', value=\'bar\', port=\'80\', port_specified=False, domain=\'.sol.no\', domain_specified=True, domain_initial_dot=True, path=\'/\', path_specified=False, secure=False, expires=1188067845, discard=False, comment=None, comment_url=None, rest={}, rfc2109=False), Cookie(version=1, name=\'bing\', value=\'bong\', port=None, port_specified=False, domain=\'.sol.no\', domain_specified=True, domain_initial_dot=True, path=\'/foo\', path_specified=True, secure=False, expires=None, discard=True, comment=None, comment_url=None, rest={}, rfc2109=False), Cookie(version=1, name=\'foo8\', value=\'bar\', port=None, port_specified=False, domain=\'www.sol.no\', domain_specified=False, domain_initial_dot=False, path=\'/%3Coo\', path_specified=True, secure=False, expires=None, discard=True, comment=None, comment_url=None, rest={}, rfc2109=False)]>' != '<_LWPCookieJar.LWPCookieJar[Cookie(version=1, name=\'wow\', value=\'flutter\', port=None, port_specified=False, domain=\'.a.acme.com\', domain_specified=True, domain_initial_dot=True, path=\'/\', path_specified=False, secure=False, expires=None, discard=True, comment=None, comment_url=None, rest={}, rfc2109=False), Cookie(version=1, name=\'ping\', value=\'pong\', port=None, port_specified=False, domain=\'.acme.com\', domain_specified=True, domain_initial_dot=False, path=\'/\', path_specified=False, secure=False, expires=None, discard=True, comment=None, comment_url=None, rest={}, rfc2109=False), Cookie(version=1, name=\'bang\', value=\'wallop\', port=\'90,100,80,8080\', port_specified=True, domain=\'.sol.no\', domain_specified=True, domain_initial_dot=True, path=\'/\', path_specified=False, secure=False, expires=1188067822, discard=False, comment=\'Just kidding! ("|\\\\\\\\) \', comment_url=None, rest={}, rfc2109=False), Cookie(version=1, name=\'foo9\', value=\'bar\', port=\'80\', port_specified=False, domain=\'.sol.no\', domain_specified=True, domain_initial_dot=True, path=\'/\', path_specified=False, secure=False, expires=1188067822, discard=False, comment=None, comment_url=None, rest={}, rfc2109=False), Cookie(version=1, name=\'bing\', value=\'bong\', port=None, port_specified=False, domain=\'.sol.no\', domain_specified=True, domain_initial_dot=True, path=\'/foo\', path_specified=True, secure=False, expires=None, discard=True, comment=None, comment_url=None, rest={}, rfc2109=False), Cookie(version=1, name=\'foo8\', value=\'bar\', port=None, port_specified=False, domain=\'www.sol.no\', domain_specified=False, domain_initial_dot=False, path=\'/%3Coo\', path_specified=True, secure=False, expires=None, discard=True, comment=None, comment_url=None, rest={}, rfc2109=False)]>'

----------------------------------------------------------------------
Ran 53 tests in 0.201s

FAILED (failures=4)
test test_cookielib failed -- errors occurred; run in verbose mode for details
make: *** [test] Error 1
----
Comment 1 Dirkjan Ochtman gentoo-dev 2010-10-27 10:26:16 UTC
Can this still be reproduced with recent Python? IIRC I ran the tests with Europe/Amsterdam as the timezone and I didn't see any failures like these.
Comment 2 Arfrever Frehtes Taifersar Arahesis (RETIRED) gentoo-dev 2010-10-29 20:10:49 UTC
(In reply to comment #1)

TAI timezones are in /usr/share/zoneinfo/right directory.
Comment 3 Ian Delaney (RETIRED) gentoo-dev 2015-09-14 07:06:49 UTC
/usr/share/zoneinfo/TAI no longer even exists