Warn users if KNX has no devices configured (#39899)

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
This commit is contained in:
Marvin Wichmann 2020-09-11 13:09:31 +02:00 committed by Paulus Schoutsen
parent 1720b71d62
commit 3d4913348a

View File

@ -148,6 +148,12 @@ async def async_setup(hass, config):
discovery.async_load_platform(hass, platform.value, DOMAIN, {}, config) discovery.async_load_platform(hass, platform.value, DOMAIN, {}, config)
) )
if not hass.data[DATA_KNX].xknx.devices:
_LOGGER.warning(
"No KNX devices are configured. Please read "
"https://www.home-assistant.io/blog/2020/09/17/release-115/#breaking-changes"
)
hass.services.async_register( hass.services.async_register(
DOMAIN, DOMAIN,
SERVICE_KNX_SEND, SERVICE_KNX_SEND,