If a device on the network presented a bad name, zeroconf
would throw zeroconf.BadTypeInNameException and the service
browser would die off. We now trap the exception and continue.
* Ensure we do not start discovered flows until after the start event has fired
This change makes zeroconf and ssdp match discovery behavior of not
creating config flows until the start event has been fired. This
prevents config flow creation/dependency installs for discovered
config flows from competing for cpu time during startup.
* Start discovery/service browser/ssdp when EVENT_HOMEASSISTANT_STARTED is fired instead of EVENT_HOMEASSISTANT_START
* Ensure homekit_controller recieves zeroconf c# updates
If an integration has a homekit config flow step
homekit controller would not see updates for
devices that were paired with it and would not
rescan for changes.
* Only send updates to homekit controller if the device is paired
This avoids the device showing up a second time.
* remove debug
* fix refactor error
Each ServerBrowser currently runs in its own thread which
processes every A or AAAA record update per instance.
As the list of zeroconf names we watch for grows, each additional
ServiceBrowser would process all the A and AAAA updates on the network.
To avoid overwhemling the system we pre-filter here and only process
DNSPointers for the configured record name (type)
* enhance zeroconf service info decoding to include raw bytes
* Update homeassistant/components/zeroconf/__init__.py
Co-Authored-By: Paulus Schoutsen <paulus@home-assistant.io>
* fix test based on last commit
* fix test based on last commit
* remove .keys() when asserting processed and raw service info properties
Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
* use isort to sort imports for components starting with 'z'
* add skip to end of zha/core/channels/__init__.py
* put 'pylint: disable=import-error' at the right place
* remove the import of config_flow in zha/__init__.py
According to @balloob it is no longer needed.
* revert previous commit
* isort:skip homeassistant/components/zha/__init__.py completely