class_docstr: Singleton class for CLI logging.
  
  Without calling 'cli_logger.configure', the CLILogger will default
  to 'record' style logging.
  
  Attributes:
      color_mode (str):
          Can be "true", "false", or "auto".
  
          Enables or disables `colorful`.
  
          If `color_mode` is "auto", is set to `not stdout.isatty()`
      indent_level (int):
          The current indentation level.
  
          All messages will be indented by prepending `"  " * indent_level`
      vebosity (int):
          Output verbosity.
  
          Low verbosity will disable `verbose` and `very_verbose` messages.
class_docstr_tok: ["Singleton","class","for","CLI","logging",".","Without","calling","'cli_logger.configure","'",",","the","CLILogger","will","default","to","'record","'","style","logging",".","Attributes",":","color_mode","(","str",")",":","Can","be","``","true","''",",","``","false","''",",","or","``","auto","''",".","Enables","or","disables","`","colorful","`",".","If","`","color_mode","`","is","``","auto","''",",","is","set","to","`","not","stdout.isatty","(",")","`","indent_level","(","int",")",":","The","current","indentation","level",".","All","messages","will","be","indented","by","prepending","`","``","``","*","indent_level","`","vebosity","(","int",")",":","Output","verbosity",".","Low","verbosity","will","disable","`","verbose","`","and","`","very_verbose","`","messages","."]
docstr: Proxy for printing messages.
  
  Args:
      msg: Message to print.
      linefeed (bool):
          If `linefeed` is `False` no linefeed is printed at the
          end of the message.
code: def _print(
      self,
      msg: str,
      _level_str: str = "INFO",
      _linefeed: bool = True,
      end: str = None,
  ):
      """Proxy for printing messages.
  
      Args:
          msg: Message to print.
          linefeed (bool):
              If `linefeed` is `False` no linefeed is printed at the
              end of the message.
      """
      if self.pretty:
          rendered_message = "  " * self.indent_level + msg
      else:
          if msg.strip() == "":
              return
          caller_info = _external_caller_info()
          record = logging.LogRecord(
              name="cli",
              # We override the level name later
              # TODO(maximsmol): give approximate level #s to our log levels
              level=0,
              # The user-facing logs do not need this information anyway
              # and it would be very tedious to extract since _print
              # can be at varying depths in the call stack
              # TODO(maximsmol): do it anyway to be extra
              pathname=caller_info["filename"],
              lineno=caller_info["lineno"],
              msg=msg,
              args={},
              # No exception
              exc_info=None,
          )
          record.levelname = _level_str
          rendered_message = self._formatter.format(record)
  
      # We aren't using standard python logging convention, so we hardcode
      # the log levels for now.
      if _level_str in ["WARNING", "ERROR", "PANIC"]:
          stream = sys.stderr
      else:
          stream = sys.stdout
  
      if not _linefeed:
          stream.write(rendered_message)
          stream.flush()
          return
  
      kwargs = {"end": end}
      print(rendered_message, file=stream, **kwargs)
  
imports: import inspect
  import logging
  import os
  import sys
  import time
  from contextlib import contextmanager
  from functools import wraps
  from typing import Any, Callable, Dict, List, Optional, Tuple
  import click
  import colorama
  import ray
label_desc: Use image node_id 12 for calling the _CliLogger obj's underlying member method code with example usage: obj._print(msg, _level_str, _linefeed, end) without return types