From 3314588773e79c0a9c0534ed6bc02652de278bef Mon Sep 17 00:00:00 2001 From: yumoqing Date: Thu, 12 Mar 2026 21:54:28 +0800 Subject: [PATCH] bugfix --- xls2ddl/json2ddl.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/xls2ddl/json2ddl.py b/xls2ddl/json2ddl.py index 9978e30..1158996 100644 --- a/xls2ddl/json2ddl.py +++ b/xls2ddl/json2ddl.py @@ -26,7 +26,11 @@ def xls2ddl(xlsfile,dbtype): data = None if xlsfile.endswith('.json'): with codecs.open(xlsfile,'r','utf-8') as f: - data = json.load(f) + try: + data = json.load(f) + except Exception as e: + print(f'{f}:error({e})') + raise e if data is None: print(xlsfile, 'not data return') return