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

Climate issue 2024.1 #297

Closed
collateral87 opened this issue Jan 3, 2024 · 4 comments
Closed

Climate issue 2024.1 #297

collateral87 opened this issue Jan 3, 2024 · 4 comments
Labels
bug Something isn't working

Comments

@collateral87
Copy link

Hi, since 2024.1 the following issue is showing on startup:

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 "<frozen importlib._bootstrap>", line 1204, in _gcd_import File "<frozen importlib._bootstrap>", line 1176, in _find_and_load File "<frozen importlib._bootstrap>", line 1147, in _find_and_load_unlocked File "<frozen importlib._bootstrap>", line 690, in _load_unlocked File "<frozen importlib._bootstrap_external>", line 940, in exec_module File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed File "/config/custom_components/magic_areas/climate.py", line 44, in <module> TARGET_TEMPERATURE | TARGET_TEMPERATURE_RANGE | PRESET_MODE ^^^^^^^^^^^^^^^^^^ NameError: name 'TARGET_TEMPERATURE' is not defined

this issue came up because of https://developers.home-assistant.io/blog/2023/12/28/support-feature-magic-numbers-deprecation

@collateral87 collateral87 added the bug Something isn't working label Jan 3, 2024
@Fossy777
Copy link

Fossy777 commented Jan 4, 2024

Additionally, also this error messages come up in 2024.1, maybe due to same or similar reasons:

  • TEMP_CELSIUS was used from magic_areas, this is a deprecated constant which will be removed in HA Core 2025.1. Use UnitOfTemperature.CELSIUS instead
  • TEMP_FAHRENHEIT was used from magic_areas, this is a deprecated constant which will be removed in HA Core 2025.1. Use UnitOfTemperature.FAHRENHEIT instead

@tbrasser
Copy link
Contributor

tbrasser commented Jan 4, 2024

Fix here: #298
Based on: daenny/climate_group#67 (comment)

@jseidl
Copy link
Owner

jseidl commented Jan 21, 2024

Merged #298, coming up on next release. Unfortunately master is a bit polluted with other changes and I'm not smart enough to cherrypick after the mess I've made so no hotfix release!

Meanwhile you can download the climate.py and overwrite the one in your custom_components/magic_areas folder

@jseidl
Copy link
Owner

jseidl commented Feb 2, 2024

Closing this one as fix is merged and will be released soon. Resolved by #298

@jseidl jseidl closed this as completed Feb 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants