code: def buildErrorResponse(self, request, error=None):
          
          if error is not None:
              cls, e, tb = error
          else:
              cls, e, tb = sys.exc_info()
  
          return remoting.Response(build_fault(cls, e, tb, self.gateway.debug),
              status=remoting.STATUS_ERROR)
docs: Builds an error response.
  
          @param request: The AMF request
          @type request: L{Request<pyamf.remoting.Request>}
          @return: The AMF response
          @rtype: L{Response<pyamf.remoting.Response>}