Package tipy :: Module lg
[hide private]
[frames] | no frames]

Module lg

source code

A class to format the log messages + the logger instance.

Classes [hide private]
  ColorFormatter
Add color to log messages by overring logging.Formater methods.
Variables [hide private]
  CNRM = '\x1b[0m'
  CBLK = '\x1b[30m'
  CRED = '\x1b[31m'
  CGRN = '\x1b[32m'
  CYEL = '\x1b[33m'
  CBLU = '\x1b[34m'
  CMAG = '\x1b[35m'
  CCYN = '\x1b[36m'
  CWHT = '\x1b[37m'
  BNRM = '\x1b[1m\x1b[00m'
  BBLK = '\x1b[1m\x1b[30m'
  BRED = '\x1b[1m\x1b[31m'
  BGRN = '\x1b[1m\x1b[32m'
  BYEL = '\x1b[1m\x1b[33m'
  BBLU = '\x1b[1m\x1b[34m'
  BMAG = '\x1b[1m\x1b[35m'
  BCYN = '\x1b[1m\x1b[36m'
  BWHT = '\x1b[1m\x1b[37m'
  BOLD = '\x1b[1m'
  CF = ColorFormatter()
  handler = StreamHandler()
  lg = getLogger('root')
The logger which can be used anywhere in the program
  __package__ = 'tipy'