class_docstr: This class is a simple wrapper maintaining loaded query objects from
  the current TabPy instance. `query_objects` is a dictionary that
  maps query object URI to query objects
  
  The query_objects schema is as follow:
  
  {'version': <current-successfuly-loaded-version>,
   'last_error':<your-recent-error-to-load-model>,
   'endpoint_obj':<loaded_query_objects>,
   'type':<object-type>,
   'status':<LoadSuccessful-or-LoadFailed-or-LoadInProgress>}
class_docstr_tok: ["This","class","is","a","simple","wrapper","maintaining","loaded","query","objects","from","the","current","TabPy","instance",".","`","query_objects","`","is","a","dictionary","that","maps","query","object","URI","to","query","objects","The","query_objects","schema","is","as","follow",":","{","'version","'",":","<","current-successfuly-loaded-version",">",",","'last_error","'",":","<","your-recent-error-to-load-model",">",",","'endpoint_obj","'",":","<","loaded_query_objects",">",",","'type","'",":","<","object-type",">",",","'status","'",":","<","LoadSuccessful-or-LoadFailed-or-LoadInProgress",">","}"]
docstr: Execute a QueryObject query
docstr_tok: ["Execute","a","QueryObject","query"]
code: def query(self, object_uri, params, uid):
      """Execute a QueryObject query"""
      logger.debug(f"Querying Python service {object_uri}...")
      try:
          if not isinstance(params, dict) and not isinstance(
              params, list
          ):
              return QueryFailed(
                  uri=object_uri,
                  error=(
                      "Query parameter needs to be a dictionary or a list"
                      f". Given value is of type {type(params)}"
                  ),
              )
  
          obj_info = self.query_objects.get(object_uri)
          logger.debug(f"Found object {obj_info}")
          if obj_info:
              pred_obj = obj_info["endpoint_obj"]
              version = obj_info["version"]
  
              if not pred_obj:
                  return QueryFailed(
                      uri=object_uri,
                      error=(
                          "There is no query object associated to the "
                          f"endpoint: {object_uri}"
                      ),
                  )
  
              logger.debug(
                  f"Querying endpoint with params ({params})..."
              )
              if isinstance(params, dict):
                  result = pred_obj.query(**params)
              else:
                  result = pred_obj.query(*params)
  
              return QuerySuccessful(object_uri, version, result)
          else:
              return UnknownURI(object_uri)
      except Exception as e:
          logger.exception(e)
          err_msg = format_exception(e, "/query")
          logger.error(err_msg)
          return QueryFailed(uri=object_uri, error=err_msg)
  
file_path: TabPy/tabpy/tabpy_server/psws/python_service.py
imports: import concurrent.futures
  import logging
  from tabpy.tabpy_server.common.util import format_exception
  from tabpy.tabpy_server.common.messages import LoadObject, DeleteObjects, FlushObjects, CountObjects, ListObjects, UnknownMessage, LoadFailed, ObjectsDeleted, ObjectsFlushed, QueryFailed, QuerySuccessful, UnknownURI, DownloadSkipped, LoadInProgress, ObjectCount, ObjectList
  from tabpy.tabpy_tools.query_object import QueryObject
label_desc: Use image node_id 8 for calling the PythonService obj's underlying member method code with example usage: obj.query(object_uri, params, uid) and returns: QueryFailed, QuerySuccessful, UnknownURI, QueryFailed, QueryFailed