def METHOD_NAME(self, msg):
    try:
        file_name = "{}-{}.log".format(config.root.parallel.worker_error_file, self.client_id)
        worker_error_file = os.path.join(config.root.parallel.workers_error_dir, file_name)
        with open(worker_error_file, 'a') as error_file:
            error_file.write(msg)
    except OSError as err:
        _logger.error("Failed to write to worker error file, error: {}", err, extra={'capture': False})