Closed edwardtfn closed 1 year ago
I am having very similar issue:
Logger: homeassistant.components.climate
Source: components/climate/__init__.py:274
Integration: Climate ([documentation](https://www.home-assistant.io/integrations/climate), [issues](https://github.com/home-assistant/home-assistant/issues?q=is%3Aissue+is%3Aopen+label%3A%22integration%3A+climate%22))
First occurred: 3:43:46 PM (4 occurrences)
Last logged: 8:21:33 PM
Error adding entities for domain climate with platform sonoff
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 428, in async_add_entities
await asyncio.gather(*tasks)
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 605, in _async_add_entity
capabilities=entity.capability_attributes,
File "/usr/src/homeassistant/homeassistant/components/climate/__init__.py", line 274, in capability_attributes
if supported_features & ClimateEntityFeature.TARGET_HUMIDITY:
TypeError: unsupported operand type(s) for &: 'NoneType' and 'ClimateEntityFeature'
I have exact same issue.
2022-11-20 09:41:37.890 WARNING (MainThread) [custom_components.sonoff.core.ewelink.cloud] Cloud processing error
Traceback (most recent call last):
File "/config/custom_components/sonoff/core/ewelink/cloud.py", line 286, in run_forever
await self._process_ws_msg(resp)
File "/config/custom_components/sonoff/core/ewelink/cloud.py", line 337, in _process_ws_msg
self.dispatcher_send(SIGNAL_UPDATE, data)
File "/config/custom_components/sonoff/core/ewelink/base.py", line 59, in dispatcher_send
handler(*args, **kwargs)
File "/config/custom_components/sonoff/core/ewelink/__init__.py", line 188, in cloud_update
self.dispatcher_send(did, params)
File "/config/custom_components/sonoff/core/ewelink/base.py", line 59, in dispatcher_send
handler(*args, **kwargs)
File "/config/custom_components/sonoff/core/entity.py", line 112, in internal_update
self._async_write_ha_state()
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 579, in _async_write_ha_state
attr = self.capability_attributes
File "/usr/src/homeassistant/homeassistant/components/climate/__init__.py", line 274, in capability_attributes
if supported_features & ClimateEntityFeature.TARGET_HUMIDITY:
TypeError: unsupported operand type(s) for &: 'NoneType' and 'ClimateEntityFeature'
Home Assistant 2022.11.3 Supervisor 2022.10.2 Operating System 9.3 Frontend 20221108.0 - latest
this is the debug output. it looks like error because NSPanel output does not have correct humidity output?
2022-11-20 09:51:56 [D] 100148b7c8 <= Cloud3 | {'temperature': 17, 'humidity': 'blank', 'tempUnit': 1} | None
2022-11-20 09:51:56 [W] Cloud processing error| File "/config/custom_components/sonoff/core/ewelink/cloud.py", line 286, in run_forever| await self._process_ws_msg(resp)|TypeError: unsupported operand type(s) for &: 'NoneType' and 'ClimateEntityFeature'|
``
This problem should be fixed in latests Hass versions. But I have added fix to old Hass versions like 2022.11.3
I'm getting this error from my NSPanel since a while. Tried to update both Home Assistant and the panel, but the problem persist.
Any idea?
Home Assistant 2022.10.5 Supervisor 2022.10.0 Operating System 9.3 Frontend 20221010.0 - latest