mirror of
https://github.com/langbot-app/LangBot.git
synced 2025-11-25 03:15:06 +08:00
fix: 首次启动时无法创建配置文件
This commit is contained in:
9
main.py
9
main.py
@@ -12,10 +12,6 @@ import asyncio
|
||||
|
||||
sys.path.append(".")
|
||||
|
||||
from pkg.utils.log import init_runtime_log_file, reset_logging
|
||||
from pkg.config import manager as config_mgr
|
||||
from pkg.config.impls import pymodule as pymodule_cfg
|
||||
|
||||
|
||||
def check_file():
|
||||
# 检查是否有banlist.py,如果没有就把banlist-template.py复制一份
|
||||
@@ -58,6 +54,11 @@ def check_file():
|
||||
# 初始化相关文件
|
||||
check_file()
|
||||
|
||||
from pkg.utils.log import init_runtime_log_file, reset_logging
|
||||
from pkg.config import manager as config_mgr
|
||||
from pkg.config.impls import pymodule as pymodule_cfg
|
||||
|
||||
|
||||
try:
|
||||
import colorlog
|
||||
except ImportError:
|
||||
|
||||
Reference in New Issue
Block a user