[Twisted-Python] XMLRPC get IP address

exarkun at twistedmatrix.com exarkun at twistedmatrix.com
Mon Dec 14 13:01:35 EST 2009

On 05:32 pm, landreville at deadtreepages.com wrote:
>I've looked through the mailing list and already found this reference 
>to get
>the IP address when using xmlrpc:
>But it is not working.
>I have added this to my class that inherits from xmlrpc.XMLRPC
>def render(self, request):
>self.request = request
>xmlrpc.XMLRPC.render(self, request)
>Now when I call any function the log says:
>2009-12-14 12:29:18-0500 [-]
>exceptions.UserWarning: Warning! request.finish called twice.
>I have two XMLRPC classes, and one of them is a subHandler, but the
>subhandler's render method never gets called as far as I've seen (so it
>shouldnt be causing request.finish to be called twice)  and just to be 
>I added this to only the parent XMLRPC class.
>Any ideas why this would cause request.finish to be called twice?

Make sure you return the result of calling xmlrpc.XMLRPC.render.


More information about the Twisted-Python mailing list