JoDehli / PyLoxone

Python Loxone binding
Apache License 2.0
162 stars 40 forks source link

Error with 0.6.2 - Downgrade to 0.6.1 #237

Closed KurtKeunen closed 3 months ago

KurtKeunen commented 3 months ago

Describe the bug

Updating to the latest version of Loxone config/miniserver and the latest version of Pyloxone in Hac i got the 2 errors and non of the climate entities load

Firmware of your Miniserver

14.5.12.7

HomeAssistant install method

Hacs

Version of HomeAssistant

Core 2024.1.6 Supervisor 2023.12.1 Operating System 11.4 Frontend 20240104.0

Version of Pyloxone

0.6.2

Update pyloxone

yes

Log


Logger: homeassistant.setup Source: setup.py:403 First occurred: 9:21:18 PM (2 occurrences) Last logged: 9:21:18 PM

Unable to prepare setup for platform 'loxone.climate': Platform not found (Exception importing custom_components.loxone.climate).


Logger: homeassistant.loader Source: loader.py:842 First occurred: 9:21:18 PM (2 occurrences) Last logged: 9:21:18 PM

Unexpected exception importing platform custom_components.loxone.climate Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/loader.py", line 842, in get_platform cache[full_name] = self._import_platform(platform_name) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/loader.py", line 859, in _import_platform return importlib.import_module(f"{self.pkg_path}.{platform_name}") ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.11/importlib/init.py", line 126, in import_module return _bootstrap._gcd_import(name[level:], package, level) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "", line 1204, in _gcd_import File "", line 1176, in _find_and_load File "", line 1147, in _find_and_load_unlocked File "", line 690, in _load_unlocked File "", line 940, in exec_module File "", line 241, in _call_with_frames_removed File "/config/custom_components/loxone/climate.py", line 108, in class LoxoneRoomControllerV2(LoxoneEntity, ClimateEntity, ABC): File "/config/custom_components/loxone/climate.py", line 114, in LoxoneRoomControllerV2 | ClimateEntityFeature.TURN_OFF ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.11/enum.py", line 784, in getattr raise AttributeError(name) from None AttributeError: TURN_OFF


estragonator commented 3 months ago

I am having the same issue, I think the problem is that the newest release of PyLoxone implemented features that are based on the dev version of homeassistant and have not been released yet through the stable release channel.

As you can see the release 2024.1.6 does not have the "TURN_OFF" flag yet: https://github.com/home-assistant/core/blob/2024.1.6/homeassistant/components/climate/const.py#L165 It was only added here: https://github.com/home-assistant/core/commit/bc720b48b476d2fa1ad754166d6aca72e0d180cf and included in pre-release https://github.com/home-assistant/core/releases/tag/2024.2.0b2

I assume it will be working again with the first february release of HA

funbirdcas commented 3 months ago

same here

JoDehli commented 3 months ago

@KurtKeunen @estragonator @funbirdcas Ok I saw it. I tested only against my dev environment which is already using the new features. I disabled the release as long as homeassistant is not updated.

KurtKeunen commented 3 months ago

2024.2.0 has been released, this 0.6.2 probably works now?

estragonator commented 3 months ago

I can confirm 0.6.2 works with 2024.2.0 in my setup.

On Thu, Feb 8, 2024 at 9:43 PM Kurt Keunen @.***> wrote:

2024.2.0 has been released, this 0.6.2 probably works now?

— Reply to this email directly, view it on GitHub https://github.com/JoDehli/PyLoxone/issues/237#issuecomment-1934903194, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAD3HX22QRFAR7UVE5HRFADYSU2GHAVCNFSM6AAAAABCVSRF56VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTSMZUHEYDGMJZGQ . You are receiving this because you were mentioned.Message ID: @.***>