mirror of
https://github.com/home-assistant/core.git
synced 2025-07-23 13:17:32 +00:00
Handle server disconnection for Vodafone devices (#104650)
This commit is contained in:
parent
8c56b5ef82
commit
6a87876729
@ -97,6 +97,9 @@ class VodafoneStationRouter(DataUpdateCoordinator[UpdateCoordinatorDataType]):
|
|||||||
try:
|
try:
|
||||||
try:
|
try:
|
||||||
await self.api.login()
|
await self.api.login()
|
||||||
|
raw_data_devices = await self.api.get_devices_data()
|
||||||
|
data_sensors = await self.api.get_sensor_data()
|
||||||
|
await self.api.logout()
|
||||||
except exceptions.CannotAuthenticate as err:
|
except exceptions.CannotAuthenticate as err:
|
||||||
raise ConfigEntryAuthFailed from err
|
raise ConfigEntryAuthFailed from err
|
||||||
except (
|
except (
|
||||||
@ -117,10 +120,8 @@ class VodafoneStationRouter(DataUpdateCoordinator[UpdateCoordinatorDataType]):
|
|||||||
dev_info, utc_point_in_time
|
dev_info, utc_point_in_time
|
||||||
),
|
),
|
||||||
)
|
)
|
||||||
for dev_info in (await self.api.get_devices_data()).values()
|
for dev_info in (raw_data_devices).values()
|
||||||
}
|
}
|
||||||
data_sensors = await self.api.get_sensor_data()
|
|
||||||
await self.api.logout()
|
|
||||||
return UpdateCoordinatorDataType(data_devices, data_sensors)
|
return UpdateCoordinatorDataType(data_devices, data_sensors)
|
||||||
|
|
||||||
@property
|
@property
|
||||||
|
@ -6,5 +6,5 @@
|
|||||||
"documentation": "https://www.home-assistant.io/integrations/vodafone_station",
|
"documentation": "https://www.home-assistant.io/integrations/vodafone_station",
|
||||||
"iot_class": "local_polling",
|
"iot_class": "local_polling",
|
||||||
"loggers": ["aiovodafone"],
|
"loggers": ["aiovodafone"],
|
||||||
"requirements": ["aiovodafone==0.4.2"]
|
"requirements": ["aiovodafone==0.4.3"]
|
||||||
}
|
}
|
||||||
|
@ -380,7 +380,7 @@ aiounifi==66
|
|||||||
aiovlc==0.1.0
|
aiovlc==0.1.0
|
||||||
|
|
||||||
# homeassistant.components.vodafone_station
|
# homeassistant.components.vodafone_station
|
||||||
aiovodafone==0.4.2
|
aiovodafone==0.4.3
|
||||||
|
|
||||||
# homeassistant.components.waqi
|
# homeassistant.components.waqi
|
||||||
aiowaqi==3.0.1
|
aiowaqi==3.0.1
|
||||||
|
@ -353,7 +353,7 @@ aiounifi==66
|
|||||||
aiovlc==0.1.0
|
aiovlc==0.1.0
|
||||||
|
|
||||||
# homeassistant.components.vodafone_station
|
# homeassistant.components.vodafone_station
|
||||||
aiovodafone==0.4.2
|
aiovodafone==0.4.3
|
||||||
|
|
||||||
# homeassistant.components.waqi
|
# homeassistant.components.waqi
|
||||||
aiowaqi==3.0.1
|
aiowaqi==3.0.1
|
||||||
|
Loading…
x
Reference in New Issue
Block a user