def dumps(self):

        error = {'code': self.code,
                 'message': str(self.message)}

        if self.data is not None:
            error['data'] = self.data

        return error


#==============================================================================
# Exceptions
#
# The error-codes -32768 .. -32000 (inclusive) are reserved for pre-defined
# errors.
#
# Any error-code within this range not defined explicitly below is reserved
# for future use
#==============================================================================
Return the Exception data in a format for JSON-RPC.
dataset/ETHPy150Open flowroute/txjason/txjason/service.py/JSONRPCError.dumps