diff --git a/utils/HtmlUtils.py b/utils/HtmlUtils.py index 618ed54..fd014af 100644 --- a/utils/HtmlUtils.py +++ b/utils/HtmlUtils.py @@ -63,7 +63,8 @@ class htmlUtils: count += 1 print(f"请求失败,第{count}次重试中...") time.sleep(1) - cls.getJSON(curl) + res = requests.get(curl, headers=cls.headers,timeout=30) + data_json = res.json() return data_json @classmethod