Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Y
ydl_ai_recommender
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
闫发泽
ydl_ai_recommender
Commits
65e1c61d
Commit
65e1c61d
authored
Dec 21, 2022
by
柴鹏飞
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
解决log多次重复输出的问题
parent
2d2941aa
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
0 deletions
+5
-0
log.py
src/utils/log.py
+5
-0
No files found.
src/utils/log.py
View file @
65e1c61d
...
...
@@ -9,6 +9,11 @@ from ydl_ai_recommender.src.utils import get_project_path
def
create_logger
(
name
,
filename
=
None
,
is_rotating
=
False
):
logger
=
logging
.
getLogger
(
name
)
# 已创建同名logger后,无需再次新建
if
logger
.
handlers
:
return
logger
logger
.
setLevel
(
logging
.
DEBUG
)
# 创建handler的输出格式(formatter)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
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 comment