This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author martin.panter
Recipients dabrahams, demian.brecht, eric.araujo, karlcow, martin.panter, orsenthil
Date 2016-05-14.12:46:10
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1463229970.8.0.523530633494.issue8732@psf.upfronthosting.co.za>
In-reply-to
Content
I suspect for Demian’s 2.7 experiment, he used the older urllib.urlopen(), rather than urllib2.urlopen() as given in the original description. When I use urllib2.urlopen("http://localhost/"), I see

GET / HTTP/1.1
Accept-Encoding: identity
Host: localhost
Connection: close
User-Agent: Python-urllib/2.7

Even in the urllib (no 2) case, since it is using HTTP 1.0, I suspect not having Accept-Encoding is not such a problem.

The underlying HTTP library has always added “Accept-Encoding: identity” for HTTP 1.1 by default (https://hg.python.org/cpython/annotate/4a3e9871b41b/Lib/httplib.py#l444), so I am closing this.
History
Date User Action Args
2016-05-14 12:46:10martin.pantersetrecipients: + martin.panter, orsenthil, eric.araujo, karlcow, dabrahams, demian.brecht
2016-05-14 12:46:10martin.pantersetmessageid: <1463229970.8.0.523530633494.issue8732@psf.upfronthosting.co.za>
2016-05-14 12:46:10martin.panterlinkissue8732 messages
2016-05-14 12:46:10martin.pantercreate