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 adding entities for domain climate with platform climate_ip #49

Open
rgogada opened this issue Jul 19, 2022 · 6 comments
Open

Error adding entities for domain climate with platform climate_ip #49

rgogada opened this issue Jul 19, 2022 · 6 comments

Comments

@rgogada
Copy link

rgogada commented Jul 19, 2022

climate_ip not working after recent updates
HA: 2022.7.5
climate_ip: 4.2

Logger: homeassistant.components.climate
Source: components/climate/init.py:220
Integration: Climate (documentation, issues)
First occurred: 9:08:08 AM (2 occurrences)
Last logged: 9:08:08 AM

Error adding entities for domain climate with platform climate_ip
Error while setting up climate_ip platform for climate
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 397, in async_add_entities
await asyncio.gather(*tasks)
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 641, in _async_add_entity
await entity.add_to_platform_finish()
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 776, in add_to_platform_finish
self.async_write_ha_state()
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 532, in async_write_ha_state
self._async_write_ha_state()
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 570, in _async_write_ha_state
state = self._stringify_state(available)
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 538, in _stringify_state
if (state := self.state) is None:
File "/usr/src/homeassistant/homeassistant/components/climate/init.py", line 220, in state
return HVACMode(self.hvac_mode).value
File "/usr/local/lib/python3.10/enum.py", line 385, in call
return cls.new(cls, value)
File "/usr/local/lib/python3.10/enum.py", line 710, in new
raise ve_exc
ValueError: '' is not a valid HVACMode

@rgogada
Copy link
Author

rgogada commented Jul 20, 2022

work around: revert back to version 4.1

@rauljerico
Copy link

Same problem here.

@andriuskr
Copy link

Downgrade to 4.1 solves the issue

@d00wirre
Copy link

Have the same issue.

2022-09-16 22:18:44.811 ERROR (MainThread) [homeassistant.loader] Unexpected exception importing platform custom_components.climate_ip.climate
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/loader.py", line 681, in get_platform
cache[full_name] = self._import_platform(platform_name)
File "/usr/src/homeassistant/homeassistant/loader.py", line 698, in _import_platform
return importlib.import_module(f"{self.pkg_path}.{platform_name}")
File "/usr/local/lib/python3.10/importlib/__init__.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "<frozen importlib._bootstrap>", line 1050, in _gcd_import
File "<frozen importlib._bootstrap>", line 1027, in _find_and_load
File "<frozen importlib._bootstrap>", line 992, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
File "<frozen importlib._bootstrap>", line 1050, in _gcd_import
File "<frozen importlib._bootstrap>", line 1027, in _find_and_load
File "<frozen importlib._bootstrap>", line 1006, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 688, in _load_unlocked
File "<frozen importlib._bootstrap_external>", line 883, in exec_module
File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
File "/config/custom_components/climate_ip/__init__.py", line 3, in <module>
from .connection_request import ConnectionRequest, ConnectionRequestPrint
File "/config/custom_components/climate_ip/connection_request.py", line 1
\\import concurrent.futures
^
SyntaxError: unexpected character after line continuation character
2022-09-16 22:18:44.813 ERROR (MainThread) [homeassistant.config] Platform error: climate
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/loader.py", line 681, in get_platform
cache[full_name] = self._import_platform(platform_name)
File "/usr/src/homeassistant/homeassistant/loader.py", line 698, in _import_platform
return importlib.import_module(f"{self.pkg_path}.{platform_name}")
File "/usr/local/lib/python3.10/importlib/__init__.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "<frozen importlib._bootstrap>", line 1050, in _gcd_import
File "<frozen importlib._bootstrap>", line 1027, in _find_and_load
File "<frozen importlib._bootstrap>", line 992, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
File "<frozen importlib._bootstrap>", line 1050, in _gcd_import
File "<frozen importlib._bootstrap>", line 1027, in _find_and_load
File "<frozen importlib._bootstrap>", line 1006, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 688, in _load_unlocked
File "<frozen importlib._bootstrap_external>", line 883, in exec_module
File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
File "/config/custom_components/climate_ip/__init__.py", line 3, in <module>
from .connection_request import ConnectionRequest, ConnectionRequestPrint
File "/config/custom_components/climate_ip/connection_request.py", line 1
\\import concurrent.futures
^
SyntaxError: unexpected character after line continuation character
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/config.py", line 878, in async_process_component_config
platform = p_integration.get_platform(domain)
File "/usr/src/homeassistant/homeassistant/loader.py", line 690, in get_platform
raise ImportError(
ImportError: Exception importing custom_components.climate_ip.climate

@kem-a
Copy link

kem-a commented Oct 15, 2022

For me downgrading to 4.1 or even to 4.0 didn't help.

Edit: might be unrelated, but restarting AC unit solved my problem. Sometimes there is another log about socket creation fail. Even so I could ping and telnet to my AC unit, all seemed normal, it still failed to create socket. So, restart!

@rauljerico
Copy link

2022-10-18 13:40:10.937 ERROR (MainThread) [homeassistant.components.climate] Error adding entities for domain climate with platform climate_ip
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 691, in _async_add_entity
await entity.add_to_platform_finish()
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 777, in add_to_platform_finish
self.async_write_ha_state()
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 533, in async_write_ha_state
self._async_write_ha_state()
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 571, in _async_write_ha_state
state = self._stringify_state(available)
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 539, in _stringify_state
if (state := self.state) is None:
File "/usr/src/homeassistant/homeassistant/components/climate/init.py", line 245, in state
return HVACMode(self.hvac_mode).value
File "/usr/local/lib/python3.10/enum.py", line 385, in call
return cls.new(cls, value)
File "/usr/local/lib/python3.10/enum.py", line 710, in new
raise ve_exc
ValueError: '' is not a valid HVACMode
2022-10-18 13:40:10.952 ERROR (MainThread) [homeassistant.components.climate] Error while setting up climate_ip platform for climate
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 289, in _async_setup_platform
await asyncio.gather(*pending)
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 691, in _async_add_entity
await entity.add_to_platform_finish()
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 777, in add_to_platform_finish
self.async_write_ha_state()
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 533, in async_write_ha_state
self._async_write_ha_state()
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 571, in _async_write_ha_state
state = self._stringify_state(available)
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 539, in _stringify_state
if (state := self.state) is None:
File "/usr/src/homeassistant/homeassistant/components/climate/init.py", line 245, in state
return HVACMode(self.hvac_mode).value
File "/usr/local/lib/python3.10/enum.py", line 385, in call
return cls.new(cls, value)
File "/usr/local/lib/python3.10/enum.py", line 710, in new
raise ve_exc
ValueError: '' is not a valid HVACMode

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

5 participants