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

Error in climate component since 2025.1 #135158

Open
TheSimpleZ opened this issue Jan 9, 2025 · 1 comment
Open

Error in climate component since 2025.1 #135158

TheSimpleZ opened this issue Jan 9, 2025 · 1 comment

Comments

@TheSimpleZ
Copy link

The problem

Since 2025.1 the climate component from smarthings throws an error in my logs.
My smartthings thermostat stopped working since that appeared.

I think it might be related to this PR: #106430
I'm no python pro, but that looks like a breaking change. Unless I'm missing something, the 'in' operator is meant for lists, not bit flags.

What version of Home Assistant Core has the issue?

core-2025.1.1

What was the last working version of Home Assistant Core?

core-2024.12

What type of installation are you running?

Home Assistant Container

Integration causing the issue

Smarthings

Link to integration documentation on our website

https://www.home-assistant.io/integrations/smartthings/

Diagnostics information

No response

Example YAML snippet

No response

Anything in the logs that might be useful for us?

Error adding entity None for domain climate with platform smartthings
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 825, in _async_add_entity
    capabilities=entity.capability_attributes,
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/climate/__init__.py", line 386, in capability_attributes
    if ClimateEntityFeature.TARGET_HUMIDITY in supported_features:
       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: argument of type 'int' is not iterable

Additional information

The climate component's documentation still states that the supported_features are supposed to be bit flags. If you intend to keep using the 'in' operator, I'd suggest updating the documentation to tell people to use a list instead.
https://developers.home-assistant.io/docs/core/entity/climate/#supported-features

@home-assistant
Copy link

home-assistant bot commented Jan 9, 2025

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

No branches or pull requests

1 participant