debugging xmlrpc servers

alan dot ezust at gmail dot com alan.ezust at
Sat Jan 22 20:03:53 EST 2005

Problems with XMLRPC

I have an xmlrpc server with a method called results() which returns an

I've been able to use this function without problems when I had only
one client talking to one server. I have recently introduced a P2P
aspect to this process and now I have servers calling each other's
methods all the time.

I am running into some bugs which I am unable to debug.

I am using

As per the instructions, I called rpdb.set_trace() right before calling

Then I ran the server, and ran the client. At a certain point, the
asks the server for the results(), and instead of getting a proper
result, I
get this exception:

/usr/lib/python2.3/ in close(self=<xmlrpclib.Unmarshaller
743             raise ResponseError()
744         if self._type == "fault":
745             raise Fault(**self._stack[0])
746         return tuple(self._stack)
global Fault = <class xmlrpclib.Fault>, self = <xmlrpclib.Unmarshaller
instance>, self._stack = [{'faultCode': 1, 'faultString':
'exceptions.ValueError:too many values to unpack'}]

args = ()
faultCode = 1
faultString = 'exceptions.ValueError:too many values to unpack'

I thought that my rpdb problems were related to the fact that I was
multiply-inheriting from SocketServer.ThreadingMixIn (which I believe
a new thread for each incoming request), so I changed this:
class QueryServer(SocketServer.ThreadingMixIn,
to this:
class QueryServer(SimpleXMLRPCServer.SimpleXMLRPCServer):

I am still unable to set a breakpoint in the results() method. I'd
like to trace through it so I can figure out why I am getting this
exception. Any ideas?

More information about the Python-list mailing list