fix
This commit is contained in:
parent
6ca7ce1992
commit
a010cacd9f
@ -75,6 +75,8 @@ class pathStr:
|
||||
return week
|
||||
|
||||
class ComicPath:
|
||||
WORK_PATH = os.path.abspath(os.curdir)
|
||||
LOG_CONF_PATH = os.path.join(WORK_PATH,"logconf.yml")
|
||||
COMIC_ICON_NAME = "000"
|
||||
COMIC_ICON_SUFFIX = "jpg"
|
||||
COMIC_ICON_FILE_NAME = COMIC_ICON_NAME+"."+COMIC_ICON_SUFFIX
|
||||
|
||||
@ -2,9 +2,10 @@
|
||||
import logging
|
||||
import logging.config
|
||||
import yaml
|
||||
from common.Constant import ComicPath
|
||||
|
||||
class logger:
|
||||
with open("logconf.yml", "r",encoding="utf-8") as f:
|
||||
with open(ComicPath.LOG_CONF_PATH, "r",encoding="utf-8") as f:
|
||||
dict_conf = yaml.safe_load(f)
|
||||
logging.config.dictConfig(dict_conf)
|
||||
root = logging.getLogger()
|
||||
|
||||
Loading…
Reference in New Issue
Block a user