A standard way to log a warning to the terminal. This should not be called
from some arbitrary packager logic, only from the reporters. Instead of
calling this, add a new type of ReportableEvent instead, and implement a
proper handler in the reporter(s).
170792
function logWarning(terminal: Terminal, format: string, ...args: Array<mixed>): void {
  const str = util.format(format, ...args);
  terminal.log('%s: %s', chalk.yellow('warning'), str);
}
1162892
public void warn(Throwable throwable, String msg, Object[] argArray) {
		logIfEnabled(Level.WARNING, throwable, msg, UNKNOWN_ARG, UNKNOWN_ARG, UNKNOWN_ARG, argArray);
	}
752883
public void warning(String format, Object... args)
    {
        if (isLoggable(WARNING))
        {
            logIt(WARNING, String.format(format, args));
        }
    }
971136
def _handle_signal_gracefully(cls, signum, signame, traceback_lines):
    """"""
    # Extract the stack, and format an entry to be written to the exception log.
    formatted_traceback = cls._format_traceback(traceback_lines=traceback_lines,
                                                should_print_backtrace=True)
    signal_error_log_entry = cls._CATCHABLE_SIGNAL_ERROR_LOG_FORMAT.format(
      signum=signum,
      signame=signame,
      formatted_traceback=formatted_traceback)
    # TODO: determine the appropriate signal-safe behavior here (to avoid writing to our file
    # descriptors re-entrantly, which raises an IOError).
    # This method catches any exceptions raised within it.
    cls.log_exception(signal_error_log_entry)

    # Create a potentially-abbreviated traceback for the terminal or other interactive stream.
    formatted_traceback_for_terminal = cls._format_traceback(
      traceback_lines=traceback_lines,
      should_print_backtrace=cls._should_print_backtrace_to_terminal)
    terminal_log_entry = cls._CATCHABLE_SIGNAL_ERROR_LOG_FORMAT.format(
      signum=signum,
      signame=signame,
      formatted_traceback=formatted_traceback_for_terminal)
    # Exit, printing the output to the terminal.
    cls._exit_with_failure(terminal_log_entry)
1350784
private void logMandatoryWarning(DiagnosticPosition pos, String msg,
                                     Object... args) {
        // Note: the following log methods are safe if lintCategory is null.
        if (enforceMandatory)
            log.mandatoryWarning(lintCategory, pos, msg, args);
        else
            log.warning(lintCategory, pos, msg, args);
    }
1169212
def alert(message)
      Thread.new do
        begin
          Java::limelight.Context.instance.studio.utilities_production.alert(message)
        rescue StandardError => e
          puts "Error on alert: #{e}"
        end
      end
    end
1220595
public void warn(final Marker marker, final String message, final Throwable throwable) {
        log.warn(marker, sanitize(message), throwable);
    }
217519
function logError(terminal: Terminal, format: string, ...args: Array<mixed>): void {
  const str = util.format(format, ...args);
  terminal.log('%s: %s', chalk.red('error'), str);
}
100576
def warning(self, msg, *args, **kwargs):
        """"""
        self._log("WARNING", msg, args, kwargs)
188536
def logging_on(level=logging.WARNING):
    
    global _is_logging_on

    if not _is_logging_on:
        console = logging.StreamHandler()
        console.setFormatter(logging.Formatter("[%(levelname)s: %(asctime)s :"
                                               " %(name)s] %(message)s",
                                               '%Y-%m-%d %H:%M:%S'))
        console.setLevel(level)
        logging.getLogger('').addHandler(console)
        _is_logging_on = True

    log = logging.getLogger('')
    log.setLevel(level)
    for h in log.handlers:
        h.setLevel(level)
644809
public void warn(String loggerFqcn, Object message, Throwable t) {
        doLog(Level.WARN, loggerFqcn, message, null, t);
    }
1233855
@Override
    public void warn(Throwable t, String msgFormat, Object... args)
    {
        m_logger.warn(String.format(msgFormat, args), t);
    }
363225
def warning(self, *args) -> "Err":
        
        error = self._create_err("warning", *args)
        print(self._errmsg(error))
        return error
303308
def add_log_handler(log, handler=None, debug=None, fmt=None):
    
    if debug:
        log.setLevel(debug)
    if handler:
        # if not fmt:
        #     fmt = __LOG_FMT
        if fmt:
            handler.setFormatter(fmt)
        log.addHandler(handler)
1108060
@SuppressForbidden("legitimate sysstreams.")
  public static void warn(String message, Throwable t) {
    PrintStream w = (warnings == null ? System.err : warnings);
    try {
      w.print("WARN: ");
      w.print(message);
      if (t != null) {
        w.print(" -> ");
        try {
          t.printStackTrace(w);
        } catch (OutOfMemoryError e) {
          // Ignore, OOM.
          w.print(t.getClass().getName());
          w.print(": ");
          w.print(t.getMessage());
          w.println(" (stack unavailable; OOM)");
        }
      } else {
        w.println();
      }
      w.flush();
    } catch (OutOfMemoryError t2) {
      w.println("ERROR: Couldn't even serialize a warning (out of memory).");
    } catch (Throwable t2) {
      // Can't do anything, really. Probably an OOM?
      w.println("ERROR: Couldn't even serialize a warning.");
    }
  }
765689
public void warn(String msg, Throwable t)
	{
		log(LogLevel.WARN, msg, t);
	}
233380
public void warn(String format, Object arg) {
        if (logger.isEnabledFor(Level.WARN)) {
            FormattingTuple ft = MessageFormatter.format(format, arg);
            logger.log(FQCN, Level.WARN, ft.getMessage(), ft.getThrowable());
        }
    }