From c50ddfe8bc2d387a02ac4716050dbf9183f68208 Mon Sep 17 00:00:00 2001 From: Pierre-Louis Bonicoli Date: Tue, 14 Aug 2012 17:52:52 +0200 Subject: [PATCH] Use repr for faultCode in Fault.__repr__ issue2742 review467002 (transplanted from 56c1da6e515b54c3148c772ccc950fd051286de3) --- tryton/jsonrpc.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/tryton/jsonrpc.py b/tryton/jsonrpc.py index 0b1daa1701..59d7eccb0b 100644 --- a/tryton/jsonrpc.py +++ b/tryton/jsonrpc.py @@ -32,6 +32,11 @@ class Fault(xmlrpclib.Fault): super(Fault, self).__init__(faultCode, faultString, **extra) self.args = faultString + def __repr__(self): + return ( + "" % + (repr(self.faultCode), repr(self.faultString)) + ) class ProtocolError(xmlrpclib.ProtocolError): pass