diff --git a/common/verification.py b/common/verification.py index 1c72b53..4d80d14 100644 --- a/common/verification.py +++ b/common/verification.py @@ -16,6 +16,8 @@ def restore_field(data: dict) -> tuple: else: res[key] = v if isinstance(v, list): + if isinstance(v, dict) or isinstance(v, list): + raise ValueError(f'请检查字段:{key} 数据类型,值:{v}') sign_kv[key] = ','.join(map(lambda x: str(x), v)) else: sign_kv[key] = v diff --git a/routers/point.py b/routers/point.py index 7fec7b1..e898027 100644 --- a/routers/point.py +++ b/routers/point.py @@ -53,5 +53,6 @@ async def point(request: Request, items: DataModel): return {"code": 0, 'msg': 'ok'} except Exception as e: - msg = traceback.format_exc() - print(msg) + # msg = traceback.format_exc() + + return {"code": -1, 'msg': str(e)}