Fix devices not always reporting IP - bump aiounifi to v62 (#100149)

This commit is contained in:
Robert Svensson 2023-09-11 21:50:29 +02:00 committed by GitHub
parent 0571a75c99
commit 13cd873e38
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 5 additions and 5 deletions

View File

@ -138,7 +138,7 @@ class UnifiEntityTrackerDescriptionMixin(Generic[HandlerT, ApiItemT]):
"""Device tracker local functions."""
heartbeat_timedelta_fn: Callable[[UniFiController, str], timedelta]
ip_address_fn: Callable[[aiounifi.Controller, str], str]
ip_address_fn: Callable[[aiounifi.Controller, str], str | None]
is_connected_fn: Callable[[UniFiController, str], bool]
hostname_fn: Callable[[aiounifi.Controller, str], str | None]
@ -247,7 +247,7 @@ class UnifiScannerEntity(UnifiEntity[HandlerT, ApiItemT], ScannerEntity):
return self.entity_description.hostname_fn(self.controller.api, self._obj_id)
@property
def ip_address(self) -> str:
def ip_address(self) -> str | None:
"""Return the primary ip address of the device."""
return self.entity_description.ip_address_fn(self.controller.api, self._obj_id)

View File

@ -8,7 +8,7 @@
"iot_class": "local_push",
"loggers": ["aiounifi"],
"quality_scale": "platinum",
"requirements": ["aiounifi==61"],
"requirements": ["aiounifi==62"],
"ssdp": [
{
"manufacturer": "Ubiquiti Networks",

View File

@ -364,7 +364,7 @@ aiosyncthing==0.5.1
aiotractive==0.5.6
# homeassistant.components.unifi
aiounifi==61
aiounifi==62
# homeassistant.components.vlc_telnet
aiovlc==0.1.0

View File

@ -339,7 +339,7 @@ aiosyncthing==0.5.1
aiotractive==0.5.6
# homeassistant.components.unifi
aiounifi==61
aiounifi==62
# homeassistant.components.vlc_telnet
aiovlc==0.1.0