def _updateCheckResult(self, check_value, status, detail_msg, notification_msg=''):
        '''
        update check result in cfg table and log table
        '''
        if self.check_cfg.enabled_flag != 'Y':
            self.logger.info('The check item %s is disable in database. So the coming result will be not stored anymore.' % (self.itm_code))
            return

        self.logger.info(check_value % 'check_value %s')
        self.logger.info('check_status %s' % status)

        check_timestamp = datetime.now().strftime("%Y%m%d %H:%M:%S.%f")  # '%s'%datetime.now()
        try:
            assert(status in [const.CHECK_STATUS_NORMAL, const.CHECK_STATUS_WARN, const.CHECK_STATUS_CRITICAL])
        except Exception as ex:
            self.logger.exception(ex)
            raise ex

        # update status in check_item cfg table
        self.check_cfg.updateStatus(check_value, status, check_timestamp, detail_msg, notification_msg)

        is_critical_event = self.check_cfg.is_critical_event
        if is_critical_event == 'Y':
            self.logger.warn("The alarm is a critical level alarm.")
        is_warning_event = self.check_cfg.is_warning_event
        if is_warning_event == 'Y':
            self.logger.warn("The alarm is a warning level alarm.")

        is_new_critical_event = self.check_cfg.is_new_critical_event
        if is_new_critical_event == 'Y':
            self.logger.warn("The alarm is a new critical level alarm.")
        is_new_warning_event = self.check_cfg.is_new_warning_event
        if is_new_warning_event == 'Y':
            self.logger.warn("The alarm is a new warning level alarm.")

        check_log = dashboard_check_log()
        check_log.initCheckStatus(self.itm_code, check_timestamp, status, check_value,
                                  self.check_cfg.warning_limit, self.check_cfg.critical_limit,
                                  self.check_cfg.shadow_data, detail_msg, notification_msg,
                                  is_critical_event, is_warning_event,
                                  is_new_critical_event, is_new_warning_event)
        check_log.insertLog()
dataset/ETHPy150Open harryliu/edwin/edwinServer/common/job_state_updater.py/JobStateUpdater._updateCheckResult/swapped operands of `%`