puddly

Results 621 comments of puddly

@TheJulianJES is there a specific device that replicates this problem? I tried manually reading the `active_power` attribute of an Inovelli switch and `87` was successfully converted to `8.7` in the...

Do you think I can replicate this if I buy a `lumi.plug.maus01` device? This is the only logic I can find in ZHA for rounding: https://github.com/home-assistant/core/blob/0defe97892e088c40f08231e826c3e4b6cead255/homeassistant/components/zha/sensor.py#L280-L287 Tracing through the quirks...

I think I can see how this can happen. `LocalDataCluster` indeed uses the attribute cache to prevent attribute "reads" from actually hitting the device, but it overrides `read_attributes_raw`, not `read_attributes`,...

Ahh, that explains it! So it looks like the max wattage of the plug is 2300W. The maximum value of a `uint16s` data type is 32767, so I think a...

> But should there be some validation in zigpy to make sure that attributes can't be saved with the wrong datatype? The use of `_update_attribute` within quirks is a problem....

To debug with existing quirks and to see what will break, maybe something like this: ```diff diff --git a/zigpy/zcl/__init__.py b/zigpy/zcl/__init__.py index 7e5744e..c1b70e0 100644 --- a/zigpy/zcl/__init__.py +++ b/zigpy/zcl/__init__.py @@ -760,6 +760,21...

I'm hoping to support the OTA cluster's `current_file_version` in the same way we support `model` and `manufacturer`, in an upcoming PR.

@lukacu Open a new issue and fill out the issue template. This one hasn't seen activity in two months and is likely unrelated to your problem.

This is more of a cosmetic issue than anything else so it's pretty low priority. This issue will be closed when it's fixed.

This would need to be implemented in zigpy. Quirks are for device specific problems. General "invalid value" checking belongs in the library.