Hide HomeKit devices from discovery that are known to be problematic (#44014)

This commit is contained in:
Jc2k
2020-12-07 12:51:35 +00:00
committed by GitHub
parent 727b1d37b6
commit 6ce45e39d1
2 changed files with 27 additions and 0 deletions

View File

@@ -21,6 +21,14 @@ HOMEKIT_BRIDGE_DOMAIN = "homekit"
HOMEKIT_BRIDGE_SERIAL_NUMBER = "homekit.bridge"
HOMEKIT_BRIDGE_MODEL = "Home Assistant HomeKit Bridge"
HOMEKIT_IGNORE = [
# eufy Indoor Cam 2K Pan & Tilt
# https://github.com/home-assistant/core/issues/42307
"T8410",
# Hive Hub - vendor does not give user a pairing code
"HHKBridge1,1",
]
PAIRING_FILE = "pairing.json"
MDNS_SUFFIX = "._hap._tcp.local."
@@ -255,6 +263,10 @@ class HomekitControllerFlowHandler(config_entries.ConfigFlow):
# Devices in HOMEKIT_IGNORE have native local integrations - users
# should be encouraged to use native integration and not confused
# by alternative HK API.
if model in HOMEKIT_IGNORE:
return self.async_abort(reason="ignored_model")
# If this is a HomeKit bridge exported by *this* HA instance ignore it.
if await self._hkid_is_homekit_bridge(hkid):
return self.async_abort(reason="ignored_model")