code: def logToMaster(self, text, level=logging.INFO):
          
          logger.log(level=level, msg=("LOG-TO-MASTER: " + text))
          self.loggingMessages.append(dict(text=text, level=level))
docs: Send a logging message to the leader. The message will also be \
          logged by the worker at the same level.
  
          :param text: The string to log.
          :param int level: The logging level.