From 3fa830159c244d3224a2c7587d8d6fa6021295d3 Mon Sep 17 00:00:00 2001 From: wang zhengwei <zhengwei.wang@wizlawgic.com> Date: Fri, 25 Dec 2020 16:08:23 +0800 Subject: [PATCH] fix bug --- app/controller/report.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/controller/report.py b/app/controller/report.py index 85de402..8f19fec 100644 --- a/app/controller/report.py +++ b/app/controller/report.py @@ -59,8 +59,8 @@ class ReportHandlers(Resource): dt = DataIntegrate(ifa_id=ifa_id, customer_id=customer_id, pdf_name=pdf_name) dt.render_data() check = 1 - except: - pass + except OSError: + check = 1 print('耗时{}秒'.format(round(time.time() - start, 2))) if check == 0: return {"code":-1, "msg": "内部错误"} -- 2.18.1