mirror of
https://github.com/home-assistant/core.git
synced 2025-07-12 15:57:06 +00:00
Fix UPC ConnectBox logout and device hostnames (#39568)
This commit is contained in:
parent
6de02fc1b9
commit
70e39a26a2
@ -69,8 +69,10 @@ class UPCDeviceScanner(DeviceScanner):
|
|||||||
async def async_get_device_name(self, device: str) -> Optional[str]:
|
async def async_get_device_name(self, device: str) -> Optional[str]:
|
||||||
"""Get the device name (the name of the wireless device not used)."""
|
"""Get the device name (the name of the wireless device not used)."""
|
||||||
for connected_device in self.connect_box.devices:
|
for connected_device in self.connect_box.devices:
|
||||||
if connected_device != device:
|
if (
|
||||||
continue
|
connected_device.mac == device
|
||||||
return connected_device.hostname
|
and connected_device.hostname.lower() != "unknown"
|
||||||
|
):
|
||||||
|
return connected_device.hostname
|
||||||
|
|
||||||
return None
|
return None
|
||||||
|
@ -2,6 +2,6 @@
|
|||||||
"domain": "upc_connect",
|
"domain": "upc_connect",
|
||||||
"name": "UPC Connect Box",
|
"name": "UPC Connect Box",
|
||||||
"documentation": "https://www.home-assistant.io/integrations/upc_connect",
|
"documentation": "https://www.home-assistant.io/integrations/upc_connect",
|
||||||
"requirements": ["connect-box==0.2.7"],
|
"requirements": ["connect-box==0.2.8"],
|
||||||
"codeowners": ["@pvizeli", "@fabaff"]
|
"codeowners": ["@pvizeli", "@fabaff"]
|
||||||
}
|
}
|
||||||
|
@ -436,7 +436,7 @@ colorlog==4.2.1
|
|||||||
concord232==0.15
|
concord232==0.15
|
||||||
|
|
||||||
# homeassistant.components.upc_connect
|
# homeassistant.components.upc_connect
|
||||||
connect-box==0.2.7
|
connect-box==0.2.8
|
||||||
|
|
||||||
# homeassistant.components.eddystone_temperature
|
# homeassistant.components.eddystone_temperature
|
||||||
# homeassistant.components.eq3btsmart
|
# homeassistant.components.eq3btsmart
|
||||||
|
Loading…
x
Reference in New Issue
Block a user