其他分享
首页 > 其他分享> > loguru

loguru

作者:互联网


from loguru import logger

logger.add("1.log")
logger.debug("111111")
logger.info("2222222")
logger.warning("33333333")
logger.error("444444444")
logger.info('If you are using Python {}, prefer {feature} of course!', 3.6, feature='f-strings')

@logger.catch
def f(a,b):
    return a/b

f(0,0)

标签:info,loguru,prefer,feature,3.6,logger
来源: https://blog.csdn.net/qq_17127427/article/details/121164966