code: def check_error(self):
          
          if not self.is_done:
              raise CloudUnhandledError("Need to check if request is done, before checking for error")
          response = self.db[self.async_id]
          error_msg = response["error"]
          status_code = int(response["status_code"])
          payload = response["payload"]
          return status_code, error_msg, payload
docs: Check if the async response is an error.
  
          Take care to call `is_done` before calling `error`. Note that the error
          messages are always encoded as strings.
  
          :raises CloudUnhandledError: When not checking `is_done` first
          :return: status_code, error_msg, payload
          :rtype: tuple