调整log目录

This commit is contained in:
liuwei
2026-01-16 13:22:27 +08:00
parent f73c730fb4
commit a987902f72
2 changed files with 4 additions and 4 deletions

View File

@@ -68,7 +68,7 @@ def api_wx_logs():
lines = request.args.get('lines', 100, type=int) # 默认显示最后100行
# 修正日志文件路径计算,获取项目根目录
project_root = os.path.abspath(os.path.join(os.path.dirname(__file__), '..', '..', '..'))
project_root = os.path.abspath(os.path.join(os.path.dirname(__file__), '..', '..', '..','logs'))
if log_type == 'error':
log_file = os.path.join(project_root, 'wx_error.log')