python日志配置dsl
logconf-dsl的Python项目详细描述
用于配置python的logging模块的dsl。
安装
来自pypi,pip:
pip install logconf-dsl
直接从git,使用pip。
pip install -e git+git@github.com:joar/logconf.git
用法
importlogconffromlogconf.dslimportLogger,Handlerlogconf.configure(handlers=Handler('default','logging.StreamHandler',level='DEBUG'),root=Logger(level='ERROR',handlers=['default']),loggers=[Logger('foo','DEBUG',handlers=['default'])])