[New-bugs-announce] [issue11142] xmlrpclib.ServerProxy with verbosity produces bad output
report at bugs.python.org
Mon Feb 7 18:33:39 CET 2011
New submission from Erez Sh <erez27 at gmail.com>:
In xmlrpclib, a ServerProxy initialized with verbose=True produces an occasionally jumbled-up output, due to a multiple threads writing to stdout without synchronizing.
I noticed this happening only for incoming data (at line 1461: print "body:", repr(data) ).
I seem to have fixed it locally by accumulating all the data and printing it (within a lock) outside of the send/recv loop.
It is a useful feature for debugging and logging the 'raw' communication, but virtually useless if one can't rely on its output.
components: Library (Lib)
title: xmlrpclib.ServerProxy with verbosity produces bad output
versions: Python 2.7
Python tracker <report at bugs.python.org>
More information about the New-bugs-announce