[New-bugs-announce] [issue12144] cookielib.CookieJar.make_cookies fails for cookies with 'expires' set
report at bugs.python.org
Sun May 22 04:58:44 CEST 2011
New submission from Scott Wimer <scott.wimer at gmail.com>:
When cookielib.CookieJar().make_cookies is used to extract cookies from a urllib2 response, it crashes when it encounters a 'Set-Cookie' header entry that has an 'expires' attribute.
This crash occurs because the expires time is evaluated against the '_now' attribute of the CookieJar instance -- an attribute which is not set unless CookieJar().extract_cookies() was called previously.
Attached is a script that triggers this bug.
components: Library (Lib)
title: cookielib.CookieJar.make_cookies fails for cookies with 'expires' set
versions: Python 2.6
Added file: http://bugs.python.org/file22054/cookielib-crash.py
Python tracker <report at bugs.python.org>
More information about the New-bugs-announce