Use built-in asyncio.timeout()

This commit is contained in:
Jules 2025-05-05 22:58:41 +02:00
parent 9af80b676b
commit cb5a2c9076
Signed by: jdejaegh
GPG key ID: 99D6D184CA66933A
3 changed files with 5 additions and 8 deletions

View file

@ -12,7 +12,6 @@ from typing import Dict, List
from zoneinfo import ZoneInfo
import aiohttp
import async_timeout
from .pollen import PollenName, PollenLevel
from .const import MAP_WARNING_ID_TO_SLUG as SLUG_MAP
@ -125,7 +124,7 @@ class IrmKmiApiClient:
headers['If-None-Match'] = self._cache[url]['etag']
try:
async with async_timeout.timeout(60):
async with asyncio.timeout(60):
response = await self._session.request(
method=method,
url=url,

View file

@ -16,9 +16,8 @@ classifiers = [
]
keywords = ["weather", "weather-api", "netherlands", "weather-forecast", "pollen", "belgium", "luxembourg", "rain-radar"]
dependencies = [
"aiohttp>=3.11.0",
"async-timeout>=4.0.3",
"svgwrite>=1.4.3",
"aiohttp>=3.11.0,<4.0.0",
"svgwrite>=1.4.3,<2.0.0",
]
requires-python = ">=3.12"

View file

@ -1,3 +1,2 @@
aiohttp>=3.11.0
async-timeout>=4.0.3
svgwrite>=1.4.3
aiohttp>=3.11.0,<4.0.0
svgwrite>=1.4.3,<2.0.0