Skip to content

Commit

Permalink
chore(client): ignore warnings when logger level is 0(error) (#3129)
Browse files Browse the repository at this point in the history
  • Loading branch information
tianweidut authored Jan 17, 2024
1 parent 68e7c4c commit ea8c736
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions client/starwhale/utils/debug.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import os
import warnings

from rich import traceback

Expand Down Expand Up @@ -31,6 +32,7 @@ def init_logger(verbose: int = 0) -> None:
if verbose == 0:
lvl = console.ERROR
max_frames = 1
warnings.simplefilter(action="ignore")
elif verbose == 1:
lvl = console.WARNING
max_frames = 5
Expand Down

0 comments on commit ea8c736

Please sign in to comment.