From d1694b566e4402fbcebb431ac152154a07341539 Mon Sep 17 00:00:00 2001 From: liuwei Date: Mon, 29 Dec 2025 15:47:30 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A4=A9=E6=B0=94=E6=9F=A5=E8=AF=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- plugins/weather/main.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/plugins/weather/main.py b/plugins/weather/main.py index bc13e29..b02b3e4 100644 --- a/plugins/weather/main.py +++ b/plugins/weather/main.py @@ -522,13 +522,13 @@ class WeatherPlugin(MessagePluginInterface): # 获取实时天气 conn = aiohttp.TCPConnector(ssl=False) now_url = f'{self.api_domain}/v7/weather/now?key={self.api_key}&location={city_id}' - async with aiohttp.request('GET', now_url, connector=conn,timeout=20) as resp: + async with aiohttp.request('GET', now_url, connector=conn) as resp: now_json = await resp.json() # 获取预报 conn = aiohttp.TCPConnector(ssl=False) daily_url = f'{self.api_domain}/v7/weather/7d?key={self.api_key}&location={city_id}' - async with aiohttp.request('GET', daily_url, connector=conn,timeout=20) as resp: + async with aiohttp.request('GET', daily_url, connector=conn) as resp: daily_json = await resp.json() if now_json.get('code') != '200' or daily_json.get('code') != '200':