mirror of
https://github.com/home-assistant/core.git
synced 2025-07-07 13:27:09 +00:00
Detect wake word services in hassio discovery (#98827)
This commit is contained in:
parent
d0fc0aea40
commit
07884026c6
@ -93,9 +93,11 @@ class ConfigFlow(config_entries.ConfigFlow, domain=DOMAIN):
|
||||
if user_input is not None:
|
||||
uri = urlparse(self._hassio_discovery.config["uri"])
|
||||
if service := await WyomingService.create(uri.hostname, uri.port):
|
||||
if not any(
|
||||
asr for asr in service.info.asr if asr.installed
|
||||
) and not any(tts for tts in service.info.tts if tts.installed):
|
||||
if (
|
||||
not any(asr for asr in service.info.asr if asr.installed)
|
||||
and not any(tts for tts in service.info.tts if tts.installed)
|
||||
and not any(wake for wake in service.info.wake if wake.installed)
|
||||
):
|
||||
return self.async_abort(reason="no_services")
|
||||
|
||||
return self.async_create_entry(
|
||||
|
Loading…
x
Reference in New Issue
Block a user