Add group entity support to ZHA (#33196)
* split entity into base and entity * add initial light group support * add dispatching of groups to light * added zha group object * add group event listener * add and remove group members * get group by name * fix rebase * fix rebase * use group_id for unique_id * get entities from registry * use group name * update entity domain * update zha storage to handle groups * dispatch group entities * update light group * fix group remove and dispatch light group entities * allow picking the domain for group entities * beginning - auto determine entity domain * move methods to helpers so they can be shared * fix rebase * remove double init groups... again * cleanup startup * use asyncio create task * group entity discovery * add logging and fix group name * add logging and update group after probe if needed * test add group via gateway * add method to get group entity ids * update storage * test get group by name * update storage on remove * test group with single member * add light group tests * test some light group logic * type hints * fix tests and cleanup * revert init changes except for create task * remove group entity domain changing for now * add missing import * tricky code saving * review comments * clean up class defs * cleanup * fix rebase because I cant read * make pylint happy
This commit is contained in:
1 parent
3ee05ad4bb
commit
2a3c94bad0
16 files changed
+1084
-257
No files matched your search
@@ -110,10 +110,11 @@ def zigpy_device_mock(zigpy_app_controller):
|
||||
manufacturer="FakeManufacturer",
|
||||
model="FakeModel",
|
||||
node_descriptor=b"\x02@\x807\x10\x7fd\x00\x00*d\x00\x00",
|
||||
nwk=0xB79C,
|
||||
):
|
||||
"""Make a fake device using the specified cluster classes."""
|
||||
device = FakeDevice(
|
||||
zigpy_app_controller, ieee, manufacturer, model, node_descriptor
|
||||
zigpy_app_controller, ieee, manufacturer, model, node_descriptor, nwk=nwk
|
||||
)
|
||||
for epid, ep in endpoints.items():
|
||||
endpoint = FakeEndpoint(manufacturer, model, epid)
|
||||
|
||||
Reference in new issue
Block a user