

def success_callback(self, data, input_queue):
    logger.info('%r fetched %d bytes', self.task, len(data))
    try:
        self.task.last_metrics_raw = data
        self.task.last_status = Status.OK
        self.task.last_message = 'Success'
        self.task.last_success_time = self.task.last_attempt_time
        input_queue.put(QueueTask(METRIC_TASK_TYPE, self.task))
    except Exception as e:
        logger.warning('%r failed to process result: %r', self.task, e)
        self.schedule_next_fetch(input_queue)

dataset/ETHPy150Open XiaoMi/minos/owl/collector/management/commands/collect.py MetricSource.success_callback/original