hass-core/homeassistant/components/wemo
Joakim Plate 8910d265d6
Keep track of a context for each listener (#72702)
* Remove async_remove_listener

This avoids the ambuigity as to what happens if same callback is added multiple times.

* Keep track of a context for each listener

This allow a update coordinator to adapt what data to request on update from the backing service based on which entities are enabled.

* Clone list before calling callbacks

The callbacks can end up unregistering and modifying the dict while iterating.

* Only yield actual values

* Add a test for update context

* Factor out iteration of _listeners to helper

* Verify context is passed to coordinator

* Switch to Any as type instead of object

* Remove function which use was dropped earliers

The use was removed in 8bee25c938
2022-06-03 13:55:57 +02:00
..
translations [ci skip] Translation update 2022-05-21 00:22:49 +00:00
__init__.py All WeMo devices use the Sensor platform (#72396) 2022-05-24 16:40:14 +02:00
binary_sensor.py Bump pywemo==0.8.1 (#72400) 2022-05-24 09:53:01 +02:00
config_flow.py
const.py
device_trigger.py Adjust device_automation type hints in wemo (#72141) 2022-05-23 14:56:17 +02:00
entity.py Bump pywemo==0.8.1 (#72400) 2022-05-24 09:53:01 +02:00
fan.py Bump pywemo==0.8.1 (#72400) 2022-05-24 09:53:01 +02:00
light.py Bump pywemo==0.8.1 (#72400) 2022-05-24 09:53:01 +02:00
manifest.json Bump pywemo==0.8.1 (#72400) 2022-05-24 09:53:01 +02:00
sensor.py
services.yaml
strings.json
switch.py Bump pywemo==0.8.1 (#72400) 2022-05-24 09:53:01 +02:00
wemo_device.py Keep track of a context for each listener (#72702) 2022-06-03 13:55:57 +02:00