Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updating Home Assistant to Core Update 2025.1.0 breaks integration #326

Open
lsochia opened this issue Jan 3, 2025 · 6 comments
Open

Updating Home Assistant to Core Update 2025.1.0 breaks integration #326

lsochia opened this issue Jan 3, 2025 · 6 comments

Comments

@lsochia
Copy link

lsochia commented Jan 3, 2025

When updating home assistant to core update 2025.1.0 this breaks the GE home integration.

Restoring to backup before the core update corrects the problem

@danielgoepp
Copy link

I just upgraded, and it works fine for me. Can you provide any more details about exactly what you are experiencing? Like specific logs or error messages you are seeing. It doesn't look like a global problem though.

@tfberg
Copy link

tfberg commented Jan 4, 2025

Same thing happened for me when updating to 2025.1.0. Rollback restored the integration. Below is the log error:

Logger: homeassistant.setup
Source: setup.py:334
First occurred: 11:35:08 PM (1 occurrences)
Last logged: 11:35:08 PM

Setup failed for custom integration 'ge_home': Unable to import component: cannot import name 'DEVICE_CLASS_POWER_FACTOR' from 'homeassistant.const' (/usr/src/homeassistant/homeassistant/const.py)
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/loader.py", line 1015, in async_get_component
comp = await self.hass.async_add_import_executor_job(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
self._get_component, True
^^^^^^^^^^^^^^^^^^^^^^^^^
)
^
File "/usr/local/lib/python3.13/concurrent/futures/thread.py", line 59, in run
result = self.fn(*self.args, **self.kwargs)
File "/usr/src/homeassistant/homeassistant/loader.py", line 1075, in _get_component
ComponentProtocol, importlib.import_module(self.pkg_path)
~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/util/loop.py", line 200, in protected_loop_func
return func(*args, **kwargs)
File "/usr/local/lib/python3.13/importlib/init.py", line 88, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "", line 1387, in _gcd_import
File "", line 1360, in _find_and_load
File "", line 1331, in _find_and_load_unlocked
File "", line 935, in _load_unlocked
File "", line 1026, in exec_module
File "", line 488, in _call_with_frames_removed
File "/config/custom_components/ge_home/init.py", line 13, in
from .update_coordinator import GeHomeUpdateCoordinator
File "/config/custom_components/ge_home/update_coordinator.py", line 37, in
from .devices import ApplianceApi, get_appliance_api_type
File "/config/custom_components/ge_home/devices/init.py", line 7, in
from .oven import OvenApi
File "/config/custom_components/ge_home/devices/oven.py", line 5, in
from homeassistant.const import DEVICE_CLASS_POWER_FACTOR
ImportError: cannot import name 'DEVICE_CLASS_POWER_FACTOR' from 'homeassistant.const' (/usr/src/homeassistant/homeassistant/const.py)

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/setup.py", line 334, in _async_setup_component
component = await integration.async_get_component()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/loader.py", line 1035, in async_get_component
self._component_future.result()
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^
File "/usr/src/homeassistant/homeassistant/loader.py", line 1027, in async_get_component
comp = self._get_component()
File "/usr/src/homeassistant/homeassistant/loader.py", line 1075, in _get_component
ComponentProtocol, importlib.import_module(self.pkg_path)
~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/util/loop.py", line 200, in protected_loop_func
return func(*args, **kwargs)
File "/usr/local/lib/python3.13/importlib/init.py", line 88, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "", line 1387, in _gcd_import
File "", line 1360, in _find_and_load
File "", line 1331, in _find_and_load_unlocked
File "", line 935, in _load_unlocked
File "", line 1026, in exec_module
File "", line 488, in _call_with_frames_removed
File "/config/custom_components/ge_home/init.py", line 13, in
from .update_coordinator import GeHomeUpdateCoordinator
File "/config/custom_components/ge_home/update_coordinator.py", line 37, in
from .devices import ApplianceApi, get_appliance_api_type
File "/config/custom_components/ge_home/devices/init.py", line 7, in
from .oven import OvenApi
File "/config/custom_components/ge_home/devices/oven.py", line 5, in
from homeassistant.const import DEVICE_CLASS_POWER_FACTOR
ImportError: cannot import name 'DEVICE_CLASS_POWER_FACTOR' from 'homeassistant.const' (/usr/src/homeassistant/homeassistant/const.py)

@simbaja
Copy link
Owner

simbaja commented Jan 4, 2025

Can you confirm you're using the latest version of the integration? The import DEVICE_CLASS_POWER_FACTOR mentioned in the error is from v0.6.8 (from early 2024), which definitely is incompatible with the latest home assistant due to a lot of deprecations. Can you upgrade to the latest and try again?

@tfberg
Copy link

tfberg commented Jan 5, 2025

I have 0.6.9 installed.

image

@simbaja
Copy link
Owner

simbaja commented Jan 5, 2025

That's a pretty old version, please upgrade to the latest 0.6.15 and try again.

@tfberg
Copy link

tfberg commented Jan 7, 2025

I added the integration to HACS and then updated it. Issue has been resolved. Had totally forgotten that I had initially added it manually and updates were not occurring.

Thanks for the awesome integration!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants