dresden-elektronik / deconz-rest-plugin

deCONZ REST-API plugin to control ZigBee devices
BSD 3-Clause "New" or "Revised" License
1.9k stars 503 forks source link

DEV refresh non sleeper endpoints and simple descriptors once per session #7637

Closed manup closed 8 months ago

manup commented 8 months ago

Due to some issues in core in past versions the Simple Descriptors may have some clusters which aren't actually there. For example when reading an attribute for a non existing cluster or attribute, due to the response the cluster would be appended. This is fixed in deCONZ versions > v2.26.1 but the Simple Descriptors need to be refreshed.

In older versions this can be done manually by selecting a node and pressing 7 and 8 or via node context menu.

This PR does it automatically once per session for non sleeping devices. Proper Simple Descriptors and clusters are needed to match DDFs via matchexpr: R:hasCluster(...).

The Simple Descriptors can also change after OTA updates, in future the refresh should be done automatically after an update, for now the once per session is a ok'ish tradeoff.