Exemplo n.º 1
0
 def CheckReturn(self, cmd, return_val):
     """Raise if return value is bad."""
     if return_val != 0:
         message = (
             "Parsing output of command '{command}' failed, as command had "
             "{code} return code")
         raise abstract.ParseError(
             message.format(command=cmd, code=return_val))
Exemplo n.º 2
0
 def ParseResponse(
     self, knowledge_base: rdf_client.KnowledgeBase,
     response: rdf_client_action.ExecuteResponse
 ) -> Iterable[rdf_client_action.ExecuteResponse]:
     del knowledge_base, response  # Unused.
     raise abstract_parser.ParseError("Lorem ipsum.")