code: def call(self, method, params):
          
          msgid = self._endpoint.send_request(method, params)
          while True:
              if not self._endpoint.receive_messages():
                  raise EOFError("EOF")
              res = self._endpoint.get_response(msgid)
              if res:
                  result, error = res
                  if error is None:
                      return result
                  raise RPCError(error)
              self._process_input_notification()
              self._process_input_request()
docs: synchronous call.
          send a request and wait for a response.
          return a result.  or raise RPCError exception if the peer
          sends us an error.