From 9e1a1996c7e747b468713eabbe65233bbc163c4b Mon Sep 17 00:00:00 2001 From: zhouchengrong Date: Fri, 10 Jan 2025 15:02:28 +0800 Subject: [PATCH] =?UTF-8?q?feat=EF=BC=88=E6=96=B0=E5=8A=9F=E8=83=BD?= =?UTF-8?q?=EF=BC=89:=20fix=EF=BC=88=E4=BF=AE=E5=A4=8Dbug=EF=BC=89:=20RunT?= =?UTF-8?q?ime=E5=88=A4=E5=AE=9A=E4=BF=AE=E6=94=B9=E4=B8=BA0.05=E7=A7=92?= =?UTF-8?q?=E5=86=85=E8=A7=A6=E5=8F=91=E6=89=93=E5=8D=B0=20docs=EF=BC=88?= =?UTF-8?q?=E6=96=87=E6=A1=A3=E5=8F=98=E6=9B=B4=EF=BC=89:=20refactor?= =?UTF-8?q?=EF=BC=88=E9=87=8D=E6=9E=84=EF=BC=89:=20test(=E5=A2=9E=E5=8A=A0?= =?UTF-8?q?=E6=B5=8B=E8=AF=95):?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/service/utils/decorator.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app/service/utils/decorator.py b/app/service/utils/decorator.py index 3e86182..bc7e9f1 100644 --- a/app/service/utils/decorator.py +++ b/app/service/utils/decorator.py @@ -7,9 +7,9 @@ def RunTime(func): t1 = time.time() res = func(*args, **kwargs) t2 = time.time() - # if t2 - t1 > 0.05: - # logging.info(f"function:【{func.__name__}】,runtime:【{str(t2 - t1)}】s") - logging.info(f"function:【{func.__name__}】,runtime:【{str(t2 - t1)}】s") + if t2 - t1 > 0.05: + logging.info(f"function:【{func.__name__}】,runtime:【{str(t2 - t1)}】s") + # logging.info(f"function:【{func.__name__}】,runtime:【{str(t2 - t1)}】s") return res return wrapper