[New-bugs-announce] [issue14414] xmlrpclib leaves connection in broken state if server returns error without content-length

Joachim Bauch report at bugs.python.org
Mon Mar 26 18:14:25 CEST 2012


New submission from Joachim Bauch <mail at joachim-bauch.de>:

If a XML-RPC server returns an error page without a content-length header (for example with "transfer-encoding: chunked" instead), the method "single_request" in xmlrpclib doesn't read the response before raising a ProtocolError.
If this happens and the http connection is reused, the response is in a broken state and the next request will trigger a ResponseNotReady exception in httplib.

Possible solutions would be to explicitly close the response before raising the ProtocolError or read the response for chunked encoding.

----------
components: Library (Lib)
messages: 156828
nosy: fancycode
priority: normal
severity: normal
status: open
title: xmlrpclib leaves connection in broken state if server returns error without content-length
type: behavior
versions: Python 2.7

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


More information about the New-bugs-announce mailing list