Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
ai
/
ai-workflow
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 74ff2acf
authored
Jun 24, 2026
by
sunqi02
Committed by
胡悦
Jul 01, 2026
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
fix: 更新 AgentScope logger 配置,确保日志正确输出到文件
1 parent
439b92de
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
0 deletions
workspace/agent-admin/backend/app/infrastructure/logging.py
workspace/agent-admin/backend/app/infrastructure/logging.py
View file @
74ff2ac
...
...
@@ -56,3 +56,10 @@ def configure_logging(service_name: str, level: int = logging.INFO) -> None:
logger
.
handlers
.
clear
()
logger
.
propagate
=
True
logger
.
setLevel
(
logging
.
WARNING
)
# AgentScope 框架自己的 logger("as"),默认 propagate=False,只输出到控制台。
# 清掉它的 handler 并 propagate,让模型/工具日志进入项目的文件日志。
as_logger
=
logging
.
getLogger
(
"as"
)
as_logger
.
handlers
.
clear
()
as_logger
.
propagate
=
True
as_logger
.
setLevel
(
level
)
Write
Preview
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment