[issue22899] http.server.BaseHTTPRequestHandler.parse_request (TypeError: decoding str is not supported)

Georg Brandl report at bugs.python.org
Wed Nov 19 00:23:19 CET 2014


Georg Brandl added the comment:

With the vanilla BaseHTTPRequestHandler, this shouldn't happen. self.raw_requestline is read from a socket file, which returns bytes, so they can be decoded using str(bytes, encoding).

Can you please check if there are any third-party packages involved that call/subclass the classes from http.server and introduce a bytes/str confusion?  They might not be correctly/completely ported to Python 3 in that case.

In any case, a full traceback will be helpful to help debug this.

----------
nosy: +georg.brandl

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


More information about the Python-bugs-list mailing list