Skip to content

Commit 64d83c0

Browse files
authored
Merge pull request #247 from plugwise/0.25.13
Bugfix as suggested by huub66
2 parents baae6cd + 1c7e1f2 commit 64d83c0

File tree

3 files changed

+13
-9
lines changed

3 files changed

+13
-9
lines changed

CHANGELOG.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,10 @@
11
# Changelog
22

3-
# 0.25.12: Revert remove raising of InvalidSetupError
3+
# v0.25.13: Anna+Elga, OnOff device: base heating_state, cooling_state on central_heating_state key only
4+
- Partial solution for https://github.com/plugwise/plugwise-beta/issues/320
5+
- Improving the solution for https://github.com/home-assistant/core/issues/81839
6+
7+
# v0.25.12: Revert remove raising of InvalidSetupError
48

59
# v0.25.11: Improve/change contents building on v0.25.10
610
- Revert: Improve handling of xml-data missing, raise exception with warning; the reason for adding this fix is not clear. Needs further investigation.

plugwise/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
"""Plugwise module."""
22

3-
__version__ = "0.25.12"
3+
__version__ = "0.25.13"
44

55
from plugwise.smile import Smile
66
from plugwise.stick import Stick

plugwise/helper.py

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -971,14 +971,14 @@ def _get_appliance_data(self, d_id: str) -> DeviceData:
971971
# Anna + Elga and Adam/Anna + OnOff heater/cooler don't use intended_central_heating_state
972972
# to show the generic heating state
973973
if "c_heating_state" in data:
974-
if (self._elga and "heating_state" in data) or (
975-
self.smile_name in ("Adam", "Anna") and self._on_off_device
974+
if self._elga or (
975+
self.smile_name in ("Adam", "Smile Anna") and self._on_off_device
976976
):
977-
if data.get("c_heating_state") and not data.get("heating_state"):
978-
data["heating_state"] = True
979-
# For Adam + OnOff cooling heating_state = True means cooling is active
980-
if self._cooling_present:
981-
self._cooling_active = True
977+
data["heating_state"] = data["c_heating_state"]
978+
# For Adam + OnOff cooling, central_heating_state = True means cooling is active
979+
# For Smile Anna, _cooling_active will be corrected in the next if-construc
980+
if self._cooling_present:
981+
self._cooling_active = True
982982

983983
# Finally, remove c_heating_state from the output
984984
data.pop("c_heating_state")

0 commit comments

Comments
 (0)