From bdf9d31be31ffbf0bb293714e3c80895bbfac17b Mon Sep 17 00:00:00 2001 From: Andre Basche Date: Fri, 29 Mar 2024 13:51:35 +0100 Subject: [PATCH] Fix missing program name Andre0512/hon#188 --- pyhon/hon.py | 10 +++------- pyhon/parameter/program.py | 2 +- 2 files changed, 4 insertions(+), 8 deletions(-) diff --git a/pyhon/hon.py b/pyhon/hon.py index 0a226e4..64e7e8a 100644 --- a/pyhon/hon.py +++ b/pyhon/hon.py @@ -93,13 +93,9 @@ class Hon: if appliance.mac_address == "": return try: - await asyncio.gather( - *[ - appliance.load_attributes(), - appliance.load_commands(), - appliance.load_statistics(), - ] - ) + await appliance.load_commands() + await appliance.load_attributes() + await appliance.load_statistics() except (KeyError, ValueError, IndexError) as error: _LOGGER.exception(error) _LOGGER.error("Device data - %s", appliance_data) diff --git a/pyhon/parameter/program.py b/pyhon/parameter/program.py index 83b843f..a3fbf4b 100644 --- a/pyhon/parameter/program.py +++ b/pyhon/parameter/program.py @@ -45,7 +45,7 @@ class HonParameterProgram(HonParameterEnum): for name, parameter in self._programs.items(): if "iot_" in name: continue - if parameter.parameters.get("prCode"): + if not parameter.parameters.get("prCode"): continue if (fav := parameter.parameters.get("favourite")) and fav.value == "1": continue