[issue16611] multiple problems with Cookie.py

2013-08-15 Thread Julien Phalip
Julien Phalip added the comment: Updated the patch to use a tuple instead of a list for the cookie flags. -- Added file: http://bugs.python.org/file31307/cookies-httponly-secure-3.diff ___ Python tracker __

[issue16611] multiple problems with Cookie.py

2013-07-18 Thread Julien Phalip
Julien Phalip added the comment: Thank you for the feedback. I've updated the patch to compile the regular expression at load time. -- Added file: http://bugs.python.org/file30969/cookies-httponly-secure-2.diff ___ Python tracker

[issue16611] multiple problems with Cookie.py

2013-07-18 Thread John Dennis
John Dennis added the comment: I think your basic approach is fine and it's O.K. to break backwards compatibility. I'm not sure anyone was using the httponly and secure flags in the past because it was so broken, the logic was completely contradictory, so backwards compatibility should not tru

[issue16611] multiple problems with Cookie.py

2013-07-18 Thread Julien Phalip
Julien Phalip added the comment: I'm attaching a suggested patch to fix the issues relating to serializing/deserializing the httponly and secure flags. The main idea is that for a flag to be active, it needs to both be set and have the True value. I think this is a much more correct and saner

[issue16611] multiple problems with Cookie.py

2013-05-20 Thread Florent Xicluna
Florent Xicluna added the comment: Eric, this last one is not a bug in Cookie. This is a limitation with Python 2. See #18012. -- nosy: +flox ___ Python tracker ___

[issue16611] multiple problems with Cookie.py

2013-05-14 Thread Éric Araujo
Éric Araujo added the comment: I have just been bitten by a bug (haven’t checked if it’s covered by the added tests) where Cookies uses string.translate incorrectly: File "/usr/lib/python2.7/Cookie.py", line 323, in _quote if "" == translate(str, idmap, LegalChars): File "/usr/lib/pytho

[issue16611] multiple problems with Cookie.py

2013-03-13 Thread John Dennis
John Dennis added the comment: That's because #3073 never addressed the core problems, so yes I would expect you would see failures. The point of the attached test is to illustrate the deficiencies in Cookie.py, so apparently it's doing it's job :-) FWIW, we wrote a new cookie library to get a

[issue16611] multiple problems with Cookie.py

2013-03-13 Thread Ezio Melotti
Ezio Melotti added the comment: Even though #3073 has been fixed, I still see the same failures when I run the attached test_cookie.py. -- nosy: +ezio.melotti, r.david.murray stage: -> needs patch type: -> behavior ___ Python tracker

[issue16611] multiple problems with Cookie.py

2012-12-04 Thread John Dennis
New submission from John Dennis: There are multiple problems with Cookie.py. Some of the issues are covered in http://bugs.python.org/issue3073 which is still open (after 4.5 years). In all honesty the API and the implementation are not great perhaps the best thing would be to remove it from t