Demian Brecht added the comment:

> I think that for consistency either parse empty name-value pair as key="", 
> value=None

There is already a test present 
(https://hg.python.org/cpython/file/0469af231d22/Lib/test/test_http_cookiejar.py#l1084)
 that ensures an unset name/value pair is ignored altogether, so I don't think 
that makes sense from a backwards compatibility standpoint. For consistency, I 
kept the functionality where nameless cookies are ignored (i.e. "=foo"). I 
think that while it may be breaking backwards compatibility for buggy edge 
cases, it's more consistent with existing functionality and actually conforms 
to the RFC. That said, I'm not going to argue over it heatedly, so if you'd 
still rather see those cases permitted, let me know and I'll change it.

Valueless cookies are still permitted to keep backwards compatible as there are 
existing tests for that.

----------
Added file: http://bugs.python.org/file38416/issue23138_1.patch

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue23138>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to