#NEWLINE# def _gotError( self , failure , request , methodName ) : #NEWLINE# #INDENT# e = failure . value #NEWLINE# if isinstance ( e , SOAPpy . faultType ) : #NEWLINE# #INDENT# fault = e #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# fault = SOAPpy . faultType ( ( '%s:Server' % SOAPpy . NS . ENV_T ) , ( 'Method %s failed.' % methodName ) ) #NEWLINE# #UNINDENT# response = SOAPpy . buildSOAP ( fault , encoding = self . encoding ) #NEWLINE# self . _sendResponse ( request , response , status = 500 )