1
0
mirror of https://github.com/home-assistant/core.git synced 2025-07-03 19:37:10 +00:00

6 Commits

Author SHA1 Message Date
Ville Skyttä
24b1e01d71
Update Ruff to 0.1.8, avoid linter/formatter conflicts ()
* Disable Ruff rules that may conflict with the formatter

* Upgrade Ruff to 0.1.8

- https://github.com/astral-sh/ruff/releases/tag/v0.1.7
- https://github.com/astral-sh/ruff/releases/tag/v0.1.8

* Format with Ruff 0.1.8
2023-12-20 23:55:09 +01:00
Marc Mueller
45b4b0e990
Import ParamSpec from typing [Py310] ()
* Import ParamSpec from typing [Py310]

* Update additional imports
2023-01-23 07:28:43 +01:00
Marc Mueller
c438c26df3
Improve WLED typing () 2022-08-26 10:25:33 +02:00
Joakim Plate
8910d265d6
Keep track of a context for each listener ()
* 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 8bee25c938a123f0da7569b4e2753598d478b900
2022-06-03 13:55:57 +02:00
Franck Nijhof
652892e535
Do not swallow WLED errors () 2022-05-24 16:30:41 +02:00
Franck Nijhof
332c86ff8c
Restructure WLED integration () 2021-06-09 20:15:46 +02:00