构建:打包和开发时使用不同的配置文件
This commit is contained in:
parent
89c4121f61
commit
f604e8ac99
6 changed files with 64 additions and 5 deletions
4
log.py
4
log.py
|
@ -3,11 +3,13 @@ import logging
|
|||
import sys
|
||||
from logging.handlers import RotatingFileHandler
|
||||
|
||||
log_level = logging.INFO
|
||||
from launcher.sys_config import sys_config
|
||||
|
||||
|
||||
# 配置日志
|
||||
def setup_logger():
|
||||
log_level = sys_config.get('log_level')
|
||||
|
||||
logger = logging.getLogger("launcher.log")
|
||||
logger.setLevel(log_level)
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue