Skip to content

Commit

Permalink
Attempt to fix occasional Flo timeouts (#82408)
Browse files Browse the repository at this point in the history
* Attempt to fix occasional Flo timeouts

* remove gather
  • Loading branch information
dmulcahey authored and balloob committed Nov 20, 2022
1 parent 243941f commit b578a76
Showing 1 changed file with 4 additions and 9 deletions.
13 changes: 4 additions & 9 deletions homeassistant/components/flo/device.py
@@ -1,7 +1,6 @@
"""Flo device object."""
from __future__ import annotations

import asyncio
from datetime import datetime, timedelta
from typing import Any

Expand Down Expand Up @@ -40,14 +39,10 @@ def __init__(
async def _async_update_data(self):
"""Update data via library."""
try:
async with timeout(10):
await asyncio.gather(
*[
self.send_presence_ping(),
self._update_device(),
self._update_consumption_data(),
]
)
async with timeout(20):
await self.send_presence_ping()
await self._update_device()
await self._update_consumption_data()
except (RequestError) as error:
raise UpdateFailed(error) from error

Expand Down

0 comments on commit b578a76

Please sign in to comment.