sts-sponsors team mailing list archive
-
sts-sponsors team
-
Mailing list archive
-
Message #04996
[Bug 1970267] Re: Unable to save macaroons in MozillaCookieJar() under python3.10
** Also affects: py-macaroon-bakery (Ubuntu Jammy)
Importance: Undecided
Status: New
** Also affects: py-macaroon-bakery (Ubuntu Kinetic)
Importance: Undecided
Status: New
** Also affects: py-macaroon-bakery (Ubuntu Lunar)
Importance: Undecided
Status: Fix Released
** Changed in: py-macaroon-bakery (Ubuntu Jammy)
Status: New => Confirmed
** Changed in: py-macaroon-bakery (Ubuntu Kinetic)
Status: New => Confirmed
--
You received this bug notification because you are a member of MAAS
Maintainers, which is subscribed to py-macaroon-bakery in Ubuntu.
https://bugs.launchpad.net/bugs/1970267
Title:
Unable to save macaroons in MozillaCookieJar() under python3.10
Status in py-macaroon-bakery package in Ubuntu:
Fix Released
Status in py-macaroon-bakery source package in Jammy:
Confirmed
Status in py-macaroon-bakery source package in Kinetic:
Confirmed
Status in py-macaroon-bakery source package in Lunar:
Fix Released
Bug description:
Upstream bug report: https://github.com/go-macaroon-bakery/py-
macaroon-bakery/issues/88
See above for details, but the essential bug is that doing something
like the following:
client =
httpbakery.Client(cookies=MozillaCookieJar(".cooklefile"))
if os.path.exists(client.cookies.filename):
client.cookies.load(ignore_discard=True)
response = client.request("POST", url=url, json=payload)
client.cookies.save(ignore_discard=True)
stated throwing a traceback under python3.10:
[ELIDED]
File "/usr/lib/python3.10/http/cookiejar.py", line 2120, in save
if cookie.has_nonstandard_attr(HTTPONLY_ATTR):
File "/usr/lib/python3.10/http/cookiejar.py", line 805, in has_nonstandard_attr
return name in self._rest
TypeError: argument of type 'NoneType' is not iterable
because py-macaroon-bakery creates a http.cookiejar.Cookie() object
with the rest field set to None, causing the writing out of a cookie
file to fail.
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/py-macaroon-bakery/+bug/1970267/+subscriptions