Critical (severity 2): critical conditions
351117
public function critical($value='')
    {
        if($this->sieve->critical) {
            self::$writer->swrite(LOG_CRIT, sprintf($this->template, 'CRITICAL', $value));
        }
    }
579246
def find_critical(self, crit=True):
        
        if crit:
            flag = 1
        else:
            flag = 0
        found = []
        end = len(self)
        index = -1
        while True:
            index = libcrypto.X509_get_ext_by_critical(self.cert.cert, flag,
                                                       index)
            if index >= end or index < 0:
                break
            found.append(self[index])
        return found
202364
private Severity calculateSeverity(ILoggingEvent event) {
        if (event.getLevel().equals(Level.ERROR)) {
            return Severity.ERROR;
        } else if (event.getLevel().equals(Level.WARN)) {
            return Severity.WARNING;
        }
        return Severity.INFO;
    }
136020
public void severe(String msg) {
        if (Level.SEVERE.intValue() < levelValue) {
            return;
        }
        log(Level.SEVERE, msg);
    }
1307353
def level=(severity)
      if severity.is_a?(Integer)
        @logger.level = severity
      else
        case severity.to_s.downcase
        when 'debug'
          @logger.level = DEBUG
        when 'info'
          @logger.level = INFO
        when 'warn'
          @logger.level = WARN
        when 'error'
          @logger.level = ERROR
        when 'fatal'
          @logger.level = FATAL
        when 'unknown'
          @logger.level = UNKNOWN
        else
          raise ArgumentError, "invalid log level: #{severity}"
        end
      end
    end
772749
def severity_list(self, severity_list):
        
        allowed_values = ["INFO", "SMOKE", "WARN", "SEVERE"]  # noqa: E501
        if not set(severity_list).issubset(set(allowed_values)):
            raise ValueError(
                "Invalid values for `severity_list` [{0}], must be a subset of [{1}]"  # noqa: E501
                .format(", ".join(map(str, set(severity_list) - set(allowed_values))),  # noqa: E501
                        ", ".join(map(str, allowed_values)))
            )

        self._severity_list = severity_list
358693
public void severe(String mesg, Throwable t) {
        log(Level.SEVERE, mesg, t);
    }
783376
function(auditRuleName, severity) {
        if (!(auditRuleName in this.rules_))
            this.rules_[auditRuleName] = {};
        this.rules_[auditRuleName].severity = severity;
    }
97769
private static boolean checkCriticalValue(double score, int n, double aLevel) {
        boolean rejected=false;

        double criticalValue = Double.MAX_VALUE;
        
        double aLevelKey = aLevel;
        if(!CRITICAL_VALUES.containsKey(aLevelKey)) { //if the particular aLevel is not a default one take the closest one
            double significanceValue = 0.0;
            for(Map.Entry<Object, AssociativeArray> entry : CRITICAL_VALUES.entrySet()) {
                significanceValue = TypeInference.toDouble(entry.getKey());
                //AssociativeArray scoreList = entry.getValue();
                
                if(significanceValue<=aLevel) { //add the closest one
                    aLevelKey=significanceValue; 
                    break;
                }
            }
            
            if(!CRITICAL_VALUES.containsKey(aLevelKey)) { //it is possible that we still have not found a proper aLevel. This happens when the requested aLevel is close to 0.99999... In that case we take the largest (last)
                aLevelKey = significanceValue; //get the last available significance value on the CRITICAL_VALUES array
            }
        }

        
        if(CRITICAL_VALUES.containsKey(aLevelKey)) { //the aLevelKey is one of the standards, we can use the tables
            if(CRITICAL_VALUES.get(aLevelKey).containsKey(n)) { //if the n value exists within the table use the exact percentage
                criticalValue = CRITICAL_VALUES.get(aLevelKey).getDouble(n);
            }
            else {
                //the n is too large, use the approximation
                criticalValue=CRITICAL_VALUES.get(aLevelKey).getDouble(0);
                criticalValue/=Math.sqrt(n);
            }
        }


        if(score>criticalValue) {
            rejected=true; 
        }

        return rejected;
    }
224187
private static Severity severityFor(Level level) {
    switch (level.toInt()) {
        // TRACE
      case 5000:
        return Severity.DEBUG;
        // DEBUG
      case 10000:
        return Severity.DEBUG;
        // INFO
      case 20000:
        return Severity.INFO;
        // WARNING
      case 30000:
        return Severity.WARNING;
        // ERROR
      case 40000:
        return Severity.ERROR;
      default:
        return Severity.DEFAULT;
    }
  }
588987
def critical(self, msg, *args, **kwargs) -> Task:  # type: ignore
        
        return self._make_log_task(logging.CRITICAL, msg, args, **kwargs)
13581
@Override
    public void sendError(String message) {
        System.out.print("Critical: " + message);
        System.exit(2);
    }
96310
def severity(self):
        
        resource_list = self.traffic_incident()
        severity = namedtuple('severity', 'severity')
        if len(resource_list) == 1 and resource_list[0] is None:
            return None
        else:
            try:
                return [severity(resource['severity'])
                        for resource in resource_list]
            except (KeyError, TypeError):
                return [severity(resource['Severity'])
                        for resource in resource_list]
69944
protected void showIndicatorsForComponent(final List<Diagnostic> diags, final int severity) {
		InputModel model = getOrCreateComponentModel();
		if (severity == Diagnostic.ERROR) {
			model.errorDiagnostics.clear();
		} else {
			model.warningDiagnostics.clear();
		}
		UIContext uic = UIContextHolder.getCurrent();
		for (int i = 0; i < diags.size(); i++) {
			Diagnostic diagnostic = diags.get(i);
			// NOTE: double equals because they must be the same instance.
			if (diagnostic.getSeverity() == severity && uic == diagnostic.getContext() && this == diagnostic.getComponent()) {
				if (severity == Diagnostic.ERROR) {
					model.errorDiagnostics.add(diagnostic);
				} else {
					model.warningDiagnostics.add(diagnostic);
				}
			}
		}
	}
246455
def severity_level(self, value):
        
        if value == self._defaults['severityLevel'] and 'severityLevel' in self._values:
            del self._values['severityLevel']
        else:
            self._values['severityLevel'] = value
141731
def critical(message, category=PsyPlotCritical, logger=None):
    """"""
    if logger is not None:
        message = "[Critical warning by %s]\n%s" % (logger.name, message)
    warnings.warn(message, category, stacklevel=2)
1285391
def check_critical_load(self):
        """"""
        if self.load_avg.intervals['1m'].value > 1:
            if self.last_load_level == 1 and time.time() - self.last_load_log < 30:
                return
            self.last_load_log = time.time()
            self.last_load_level = 1
            logger.error(
                "Listener load limit exceeded, the system can't handle this!",
                extra=self._make_stats()
            )

        elif self.load_avg.intervals['1m'].value > 0.8:
            if self.last_load_level == 0.8 and time.time() - self.last_load_log < 30:
                return
            self.last_load_log = time.time()
            self.last_load_level = 0.8
            logger.warning(
                "Listener load approaching critical!",
                extra=self._make_stats()
            )

        else:
            self.last_load_log = -math.inf
            self.last_load_level = 0