chainlib

Generic blockchain access library and tooling
Info | Log | Files | Refs | README | LICENSE

log.py (312B)


      1 # standard imports
      2 import logging
      3 
      4 logging.basicConfig(level=logging.WARNING, format='%(asctime)s %(levelname)s %(filename)s:%(lineno)d %(message)s')
      5 
      6 
      7 def process_log(args, logger):
      8     if args.vv:
      9         logger.setLevel(logging.DEBUG)
     10     elif args.v:
     11         logger.setLevel(logging.INFO)
     12 
     13     return logger