yzl 2 年之前
父节点
当前提交
a0eda6ea6a
共有 1 个文件被更改,包括 2 次插入2 次删除
  1. 2 2
      apps/Weather/views.py

+ 2 - 2
apps/Weather/views.py

@@ -91,12 +91,12 @@ class GetWeather(APIView):
                         result = json.loads(temp)
                         return Response({"content": result, "msg": "success", "code": 200})
                     except Exception as e:
-                        logging.info(traceback.format_exc())
+                        logging.info(f"cityid: {cityid} province:{province} city:{city} district: {district}   {traceback.format_exc()}")
                         return Response({"msg": "请联系管理员", "code": "50001"})
                 else:
                     return Response({"content": "", "msg": "success", "code": 500})
         except Exception as e:
-            logging.info(traceback.format_exc())
+            logging.info(f"cityid: {cityid} province:{province} city:{city} district: {district}   {traceback.format_exc()}")
             return Response({"msg": "请联系管理员", "code": "50001"})