[issue2756] urllib2 add_header fails with existing unredirected_header

John J Lee report at bugs.python.org
Sat Oct 25 14:40:11 CEST 2008


John J Lee <jjlee at users.sourceforge.net> added the comment:

I agree there is a bug here: clearly the methods on the Request class
are inconsistent with AbstractHTTPHandler.do_open() .  I think Facundo's
patch is good, though it needs a test.

The general principle when fixing earlier bugs has been that the
.add_*header() methods override default headers, though there are some
reasonable violations this where the implementation relies on specific
headers being sent -- e.g. "Connection: close".

----------
nosy: +jjlee

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


More information about the Python-bugs-list mailing list