[issue5275] BaseCookie.load doesn't create Morsel objects for mappings

Mark Florisson report at bugs.python.org
Sun Feb 15 23:49:51 CET 2009


New submission from Mark Florisson <markflorisson88 at gmail.com>:

The load method, which is also called from the initializer if input is
provided, doesn't create Morsel objects for things other than strs,
because it calls self.update(rawdata), which does not invoke the custom
__setitem__.

The documentation states that when rawdata is not a string, it must be a
dictionary and providing that will be equivalent to doing

for k, v in rawdata.items():
    cookie[k] = v

So that is what it should do :)

----------
messages: 82177
nosy: eggy
severity: normal
status: open
title: BaseCookie.load doesn't create Morsel objects for mappings
type: behavior
versions: Python 2.4, Python 2.5, Python 2.6, Python 2.7, Python 3.0, Python 3.1

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue5275>
_______________________________________


More information about the Python-bugs-list mailing list