mirror of
https://github.com/home-assistant/core.git
synced 2025-07-23 05:07:41 +00:00
Fix async_timeout deprecation warning (#94594)
* Fix async_timeout deprecation warning * Combine async with
This commit is contained in:
parent
7fbeac9bbe
commit
5c3ec8774d
@ -53,8 +53,9 @@ async def load_wyoming_info(
|
||||
|
||||
for _ in range(retries + 1):
|
||||
try:
|
||||
async with AsyncTcpClient(host, port) as client:
|
||||
with async_timeout.timeout(timeout):
|
||||
async with AsyncTcpClient(host, port) as client, async_timeout.timeout(
|
||||
timeout
|
||||
):
|
||||
# Describe -> Info
|
||||
await client.write_event(Describe().event())
|
||||
while True:
|
||||
|
Loading…
x
Reference in New Issue
Block a user