logging.basicConfig(filename=train_log, format='%(asctime)s - %(name)s - %(levelname)s -%(module)s: %(message)s',
datefmt='%Y-%m-%d %H:%M:%S ',
level=logging.INFO)
logger = logging.getLogger()
KZT = logging.StreamHandler()
KZT.setLevel(logging.DEBUG)
logger.addHandler(KZT)
logger.info('abc')
Python 解决logging.info()控制台不输出问题
于 2022-02-24 16:40:22 首次发布
关键词由CSDN通过智能技术生成