klejejs / ha-thermia-heat-pump-integration Goto Github PK
View Code? Open in Web Editor NEWThermia Heat Pump Integration for Home Assistant
License: GNU General Public License v3.0
Thermia Heat Pump Integration for Home Assistant
License: GNU General Public License v3.0
Hi,
I have Thermia Calibra 12 heat pump. Temperature shows unknown in home assistant ui.
HA version: 2023.11.3
HAOS: 11.1
Thermia Heat Pump Integration: 3.3.1
Debug log:
debug.txt
Hi.
Thank you for doing a great job!
I have a problem when using on/off switch in automation.
I get an error in my automation. This is from "Trace timeline":
"Stopped because an error was encountered.." 'ThermiaWaterHeater' object has no attribute 'async_turn_off'
Am I doing something wrong or is it an issue with the integration?
From Dashboard I can change between the values (HOT_WATER, AUXILIARY, COMPRESSOR, AUTO, OFF) and it seems to be working.
When creating the automation I can just choose between "Turn off or turn on".
Is it affecting just the hot water heater or the whole heating pump?
Also the "Sensors" shows status "Unknown".
I've reinstall and Reload but nothing changes.
I'm using V3.1.1 release and Home assistant 2023.5.4
And the pump is a Thermia Diplomat Duo
Thanks in advance!
The operational_status
does not work, with the below tracelog.
Using: https://www.online-genesis.thermia.se/
Heatpump:
Calibra Eco 8
Software version
12.1.5
I don't know if it used to be a numerical value, but it appears it's either one of these now:
I don't know if the shown operational statuses are the exhaustive list, or just a subset associated with my heatpump.
Hopefully it's always a string value now and an easy fix, otherwise I would assume (not knowing how to extract the values) it's the same pattern for all of them, i.e
Let me know if there is any other information that would be helpful.
Logger: homeassistant
Source: components/sensor/__init__.py:593
First occurred: 9:10:32 AM (3478 occurrences)
Last logged: 7:47:47 PM
Error doing job: Task exception was never retrieved
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 586, in state
numerical_value = int(value)
^^^^^^^^^^
ValueError: invalid literal for int() with base 10: 'STATUS_NO_DEMAND'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 589, in state
numerical_value = float(value)
^^^^^^^^^^^^
ValueError: could not convert string to float: 'STATUS_NO_DEMAND'
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 235, in _handle_refresh_interval
await self._async_refresh(log_failures=True, scheduled=True)
File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 392, in _async_refresh
self.async_update_listeners()
File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 173, in async_update_listeners
update_callback()
File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 473, in _handle_coordinator_update
self.async_write_ha_state()
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 730, in async_write_ha_state
self._async_write_ha_state()
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 830, in _async_write_ha_state
state, attr = self._async_generate_attributes()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 771, in _async_generate_attributes
state = self._stringify_state(available)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 736, in _stringify_state
if (state := self.state) is None:
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 593, in state
raise ValueError(
ValueError: Sensor sensor.bergvarmen_operational_status has device class 'None', state class 'measurement' unit 'None' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-numeric value: 'STATUS_NO_DEMAND' (<class 'str'>)
The boost switch was present for maybe 2 or 3 days and now it disappeared.
I recently started to get errors from the integration, but i've lost the logs containing the error after i removed configuration to test.
It was a JSON decode error, suggesting that the response from the API was something else (probably some error).
Now I'm trying to set up the integration again, and getting Credentials are invalid.
in the config flow. The logs are saying the following:
2024-04-30 15:53:43.225 ERROR (MainThread) [custom_components.thermia.config_flow] Expecting value: line 1 column 1 (char 0)
The Thermia Web App is operational and i'm able to log in there.
Got this message in my logs:
Detected code that calls async_forward_entry_setup for integration thermia with title: Thermia ([email protected]) and entry_id: xxxxxxxxxxxxxxxx, during setup without awaiting async_forward_entry_setup, which can cause the setup lock to be released before the setup is done. This will stop working in Home Assistant 2025.1. Please report this issue.
First, you have my gratitude for this great integration, I really love it.
Currently my HA generates the following warnings and advises me to report it in this github issues topics.
So in an attempt to support, I'm quite new to this and not sure if its usefull. Maybe you are already aware.
If below is useless, then please ignore this message and remove it.
If you require more input, please let me know, I'll try to support as much as I can.
Thank you in advance.
Kind regards,
Vernon
HA Logging:
2024-01-07 02:33:46.316 WARNING (MainThread) [homeassistant.const] TEMP_CELSIUS was used from thermia, this is a deprecated constant which will be removed in HA Core 2025.1. Use UnitOfTemperature.CELSIUS instead, please create a bug report at https://github.com/klejejs/ha-thermia-heat-pump-integration/issues
2024-01-07 02:33:46.317 WARNING (MainThread) [homeassistant.const] TIME_HOURS was used from thermia, this is a deprecated constant which will be removed in HA Core 2025.1. Use UnitOfTime.HOURS instead, please create a bug report at https://github.com/klejejs/ha-thermia-heat-pump-integration/issues
2024-01-07 02:33:46.321 WARNING (MainThread) [homeassistant.components.water_heater] SUPPORT_OPERATION_MODE was used from thermia, this is a deprecated constant which will be removed in HA Core 2025.1. Use WaterHeaterEntityFeature.OPERATION_MODE instead, please create a bug report at https://github.com/klejejs/ha-thermia-heat-pump-integration/issues
2024-01-07 02:33:46.322 WARNING (MainThread) [homeassistant.components.water_heater] SUPPORT_TARGET_TEMPERATURE was used from thermia, this is a deprecated constant which will be removed in HA Core 2025.1. Use WaterHeaterEntityFeature.TARGET_TEMPERATURE instead, please create a bug report at https://github.com/klejejs/ha-thermia-heat-pump-integration/issues
2024-01-07 02:33:46.323 WARNING (MainThread) [homeassistant.components.water_heater] SUPPORT_OPERATION_MODE was used from thermia, this is a deprecated constant which will be removed in HA Core 2025.1. Use WaterHeaterEntityFeature.OPERATION_MODE instead, please create a bug report at https://github.com/klejejs/ha-thermia-heat-pump-integration/issues
2024-01-07 02:33:46.325 WARNING (MainThread) [homeassistant.components.water_heater] SUPPORT_TARGET_TEMPERATURE was used from thermia, this is a deprecated constant which will be removed in HA Core 2025.1. Use WaterHeaterEntityFeature.TARGET_TEMPERATURE instead, please create a bug report at https://github.com/klejejs/ha-thermia-heat-pump-integration/issues
2024-01-07 02:33:46.326 WARNING (MainThread) [homeassistant.const] TEMP_CELSIUS was used from thermia, this is a deprecated constant which will be removed in HA Core 2025.1. Use UnitOfTemperature.CELSIUS instead, please create a bug report at https://github.com/klejejs/ha-thermia-heat-pump-integration/issues
2024-01-07 02:33:46.333 WARNING (MainThread) [homeassistant.helpers.entity] Entity None (<class 'custom_components.thermia.water_heater.ThermiaWaterHeater'>) is using deprecated supported features values which will be removed in HA Core 2025.1. Instead it should use <WaterHeaterEntityFeature.TARGET_TEMPERATURE|OPERATION_MODE: 3>, please create a bug report at https://github.com/klejejs/ha-thermia-heat-pump-integration/issues and reference https://developers.home-assistant.io/blog/2023/12/28/support-feature-magic-numbers-deprecation
Hi,
Missing entities like main heater. After upgrading to latest HA, about half of Thermia classic entities are missing like the heater for viewing or changing temperature.
Half of the entites as for example water heater is still there but the most important one (for me) are gone.
I have tried restaring HA and removing the integration and adding it again but without any success. Any suggestion on what to do or is it a bug in the newest HA version?
Seems like when I go to Thermia online "https://online.thermia.se", then I can see and change things like temperature so no problem with their web.
Thanks in advance.
Hi, Fantastic work on the integration.
I would like to request a small feature, which is the ability to activate the hot water boost from homeassistant.
it seems to be located in the API as REG__HOT_WATER_BOOST in REG_GROUP_HOT_WATER.
If i find the time to sit down and look into it I might set it up and make a merge request, but since you already have most of this figured out, it might be an easy fix for you.
best regards,
Ole
Hi!
I've used your component for quite some time, although it's basically the last couple of weeks when I've actually starting controlling the heat pump (Calibra) actively since I switched to spot price. :)
Today however, it stopped working to change the target temperature. I still receive updated data such as outside temperature, brine in/out temperature etc. Checking the logs I found the following:
`This error originated from a custom integration.
Logger: ThermiaOnlineAPI.api.ThermiaAPI
Source: custom_components/thermia/water_heater.py:145
Integration: Thermia Heat Pump (documentation, issues)
First occurred: 6:26:01 PM (8 occurrences)
Last logged: 7:41:03 PM
Error setting register 29422 value. 400`
Any chance you have any idea of what's going on? Has thermia changed their api or something? Grateful for your contributions and for any help regarding this! 🙏
Cheers!
After update of HA to: 2023.10.1 the Thermia integration doesn't work. HA gets no values, and HA cannot control my heat pump.
My Thermia heat pump is: Calibra cool 7
None of the values are working.
When enable logging I get this error:
2023-10-08 12:10:27.225 ERROR (SyncWorker_0) [ThermiaOnlineAPI.api.ThermiaAPI] Error fetching device status. Status :404, Response: The resource you are looking for has been removed, had its name changed, or is temporarily unavailable.
2023-10-08 12:10:27.609 ERROR (SyncWorker_0) [ThermiaOnlineAPI.api.ThermiaAPI] Error in getting device's register group: REG_GROUP_OPERATIONAL_STATUS, Status: 404, Response: The resource you are looking for has been removed, had its name changed, or is temporarily unavailable.
2023-10-08 12:10:28.018 ERROR (SyncWorker_0) [ThermiaOnlineAPI.api.ThermiaAPI] Error in getting device's alarms. Status: 404, Response: The resource you are looking for has been removed, had its name changed, or is temporarily unavailable.
2023-10-08 12:10:29.123 ERROR (SyncWorker_1) [ThermiaOnlineAPI.api.ThermiaAPI] Error fetching device status. Status :404, Response: The resource you are looking for has been removed, had its name changed, or is temporarily unavailable.
2023-10-08 12:10:30.021 ERROR (SyncWorker_1) [ThermiaOnlineAPI.api.ThermiaAPI] Error in getting device's alarms. Status: 404, Response: The resource you are looking for has been removed, had its name changed, or is temporarily unavailable.
2023-10-08 12:10:30.405 ERROR (MainThread) [homeassistant.components.sensor] Error adding entities for domain sensor with platform thermia
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 588, in state
numerical_value = int(value)
^^^^^^^^^^
ValueError: invalid literal for int() with base 10: 'STATUS_HOTWATER'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 591, in state
numerical_value = float(value)
^^^^^^^^^^^^
ValueError: could not convert string to float: 'STATUS_HOTWATER'
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 507, in async_add_entities
await asyncio.gather(*tasks)
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 752, in _async_add_entity
await entity.add_to_platform_finish()
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1057, in add_to_platform_finish
self.async_write_ha_state()
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 779, in async_write_ha_state
self._async_write_ha_state()
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 879, in _async_write_ha_state
state, attr = self._async_generate_attributes()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 820, in _async_generate_attributes
state = self._stringify_state(available)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 785, in _stringify_state
if (state := self.state) is None:
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 595, in state
raise ValueError(
ValueError: Sensor sensor.heatpump_operational_status has device class 'None', state class 'measurement' unit 'None' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-numeric value: 'STATUS_HOTWATER' (<class 'str'>)
2023-10-08 12:10:30.425 ERROR (MainThread) [homeassistant.components.sensor] Error while setting up thermia platform for sensor
Traceback (most recent call last):
.
.
.```
Hello Krisjanis, you're doing amazing work. I thought my heat pump will never work with HA, but now it does thanks to you.
If I could ask you for adding few features, it would be very nice to have them:
of course any other feature will be greatly appreciated.
P.S. I use Danfoss DHP-AQ heat pump (Thermia Atec) and it works with your integration/python module, even if my module shows my pump as iTec (on Thermia Online and in your integration).
Thanks again for your great work!
Updated HACS to 1.24.3 and from there on there are no readings from my heatpump.
in the system CORE logg i get this message:
_2022-04-08 13:53:04 ERROR (MainThread) [homeassistant] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 137, in _handle_refresh_interval
await self._async_refresh(log_failures=True, scheduled=True)
File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 268, in _async_refresh
update_callback()
File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 328, in _handle_coordinator_update
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/sensor/init.py", line 454, in state
assert native_unit_of_measurement
AssertionError
Any body else with the same issue?
I'm getting "Credentials are invalid." with API type set to "genesis". No problem to login at https://online-genesis.thermia.se/
If I try the "classic" the integration is added correctly, but of course no heat pump since that account doesn't have any heat pump installed.
Anyone else having this problem?
I've been running this integration fine for few days but today I happened to get this error when trying to change target room temperature:
This error originated from a custom integration.
Logger: ThermiaOnlineAPI.api.ThermiaAPI
Source: custom_components/thermia/__init__.py:91
Integration: Thermia Heat Pump (documentation, issues)
First occurred: 21:36:11 (309 occurrences)
Last logged: 22:27:44
Reauthentication request failed with previous refresh token. Status: 400, Response: {"error":"invalid_grant","error_description":"AADB2C90080: The provided grant has expired. Please re-authenticate and try again. Current time: 1672518424, Grant issued time: 1672511769, Grant expiration time: 1672511624\r\nCorrelation ID: 3ece6f47-bc65-4f8c-a0d3-7fa08f538a93\r\nTimestamp: 2022-12-31 20:27:04Z\r\n"}
Reauthentication request failed with previous refresh token. Status: 400, Response: {"error":"invalid_grant","error_description":"AADB2C90080: The provided grant has expired. Please re-authenticate and try again. Current time: 1672518434, Grant issued time: 1672511769, Grant expiration time: 1672511624\r\nCorrelation ID: 87b58ffc-25ad-4400-a727-a2cfa618862b\r\nTimestamp: 2022-12-31 20:27:14Z\r\n"}
Reauthentication request failed with previous refresh token. Status: 400, Response: {"error":"invalid_grant","error_description":"AADB2C90080: The provided grant has expired. Please re-authenticate and try again. Current time: 1672518444, Grant issued time: 1672511769, Grant expiration time: 1672511624\r\nCorrelation ID: 0ae6f096-b31b-451f-843c-4666cbe751d8\r\nTimestamp: 2022-12-31 20:27:24Z\r\n"}
Reauthentication request failed with previous refresh token. Status: 400, Response: {"error":"invalid_grant","error_description":"AADB2C90080: The provided grant has expired. Please re-authenticate and try again. Current time: 1672518454, Grant issued time: 1672511769, Grant expiration time: 1672511624\r\nCorrelation ID: 9fbf3d43-f451-498b-bd03-dade1cbf136f\r\nTimestamp: 2022-12-31 20:27:34Z\r\n"}
Reauthentication request failed with previous refresh token. Status: 400, Response: {"error":"invalid_grant","error_description":"AADB2C90080: The provided grant has expired. Please re-authenticate and try again. Current time: 1672518464, Grant issued time: 1672511769, Grant expiration time: 1672511624\r\nCorrelation ID: 9f618557-456c-42ec-8189-3403d35b487e\r\nTimestamp: 2022-12-31 20:27:44Z\r\n"}
Reloading the integration helped, but that's more of an band-aid.
@andeny Mentioned:
i have tried this integration for a couple of days now and it looks great. i have one problem with the values not being updated in homeassistant. i have to manualy reload the integration or restart homeassistant to get the new values. it seems it only get them ones every restart/reload. have i missed something ?
i have activated pull in homeassistant
actually found this in the loggs if it helps
Error fetching thermia data: HTTPSConnectionPool(host='online-genesis-serviceapi.azurewebsites.net', port=443): Max retries exceeded with url: /api/v1/Registers/Installations/1533268/Groups/REG_GROUP_HOT_WATER (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7f947b51d310>: Failed to establish a new connection: [Errno 110] Operation timed out'))
Hi,
Looks that latest HA core update (2013.5 and/or OS 10.1) has caused issues:
Logger entry:
Logger: ThermiaOnlineAPI.api.ThermiaAPI
Source: custom_components/thermia/init.py:94
Integration: Thermia Heat Pump (documentation, issues)
First occurred: 6. May 2023 klo 16.46.24 (5414 occurrences)
Last logged: 09.31.03
Error fetching device info. 500
Error in getting device's alarms. 500
Target Temperature shows unknown
Home Assistant Core 2023.12.1
Home Assistant Operating System 11.2
Thermia Heat Pump Integration v3.3.1
Thermia heat pump Diplomat Inverter M
Mjukvaruversion
13.0.10
My Target temperature shows state unknown in lovelace but if i click on the on the sensor (water_heater.my_sensor_name) to show the more "detailed view" it correctly shows "Current temperature 20 °C". Please see screenshots for better understanding of what i mean.
If i search the logs for water_heater everything looks fine as far as i can see:
2024-01-08 20:11:00.487 INFO (SyncWorker_5) [homeassistant.loader] Loaded water_heater from homeassistant.components.water_heater
2024-01-08 20:11:00.663 INFO (MainThread) [homeassistant.setup] Setting up water_heater
2024-01-08 20:11:00.666 INFO (MainThread) [homeassistant.setup] Setup of domain water_heater took 0.0 seconds
2024-01-08 20:11:03.856 INFO (MainThread) [homeassistant.components.water_heater] Setting up water_heater.mqtt
2024-01-08 20:11:34.100 INFO (MainThread) [homeassistant.components.water_heater] Setting up water_heater.thermia
2024-01-08 20:11:00.487 INFO (SyncWorker_5) [homeassistant.loader] Loaded water_heater from homeassistant.components.water_heater
First off all thank you for this, it seems to work fine. However the number of control options is very limited. The one thing I'm missing is being able to set the global temperature target. Is that not supported by the API or something that could be added?
Hi,
After running successfully this integration for several months, started suddenly face issue with Thermia integration this week. For some reason it does not set values to the pump. Readings seems to be updating ok.
No success so far, did try to fix it:
For example when setting temperature, log is giving error below. Any ideas what could be wrong?
This error originated from a custom integration:
Logger: ThermiaOnlineAPI.api.ThermiaAPI
Source: custom_components/thermia_water_heater/water_heater.py:145
Integration: thermia_water_heater
First occurred: 14:38:18 (2 occurrences)
Last logged: 14:38:23
Error setting register 6010 value. 400
Pump used is:
Thermia Diplomat Duo Optimum
HA version:
Home Assistant 2023.3.6
Supervisor 2023.03.2
Frontend 20230309.1 - latest
Thermia's app seems to be working just fine.
Thanks!
i updated my homeassistant to latest and got this error
Logger: homeassistant.components.sensor
Source: helpers/entity.py:220
Integration: Sensor (documentation, issues)
First occurred: 09:21:01 (4 occurrences)
Last logged: 09:22:37
Error adding entities for domain sensor with platform thermia
Error while setting up thermia platform for sensor
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 382, in async_add_entities
await asyncio.gather(*tasks)
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 510, in _async_add_entity
entry = entity_registry.async_get_or_create(
File "/usr/src/homeassistant/homeassistant/helpers/entity_registry.py", line 401, in async_get_or_create
entity_category=_convert_to_entity_category(entity_category),
File "/usr/src/homeassistant/homeassistant/helpers/entity_registry.py", line 103, in _convert_to_entity_category
return convert_to_entity_category(value, raise_report=raise_report)
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 220, in convert_to_entity_category
return EntityCategory(value)
File "/usr/local/lib/python3.9/enum.py", line 384, in call
return cls.new(cls, value)
File "/usr/local/lib/python3.9/enum.py", line 702, in new
raise ve_exc
ValueError: 'sensor' is not a valid EntityCategory
I think it is connected to a change in home assistant handling sensors and i also get this error:
Logger: homeassistant.helpers.frame
Source: helpers/frame.py:74
First occurred: 09:21:01 (16 occurrences)
Last logged: 09:22:37
Detected code that uses str (sensor) for entity category. This is deprecated and will stop working in Home Assistant 2022.4, it should be updated to use EntityCategory instead. Please report this issue.
can you help with this ?
it does not load the temp sensors any moore, see attached picture
Model: Thermia iTec
I don't think my operational status has worked before, but after upgrading today to 3.2.0 it started showing something, but seems that not all statuses are shown:
I've attached a debug file if it's any help
debug-16102023.txt
@jwictor81 You mentioned that only the following sensors are shown:
Are you using classic
or genesis
API? It could be that they are hidden because they have different values that have not been supported yet.
Hello,
It seems that since the update to core-2024.5.0 the Thermia Calibra Cool integration (Generic x86-64) does not work anymore. Is this possible?
I did not change the Password and Thermia username.
ha-thermia-heat-pump-integration 3.4.0
Removed the integration. But I cant install it no more.
https://online.thermia.se/
Credentials are invalid.! Strange
Regards
Hello, I got the following error message when trying to setup the heat pump. I do not have an internal temperature sensor,
so maybe that is a problem:
Logger: homeassistant.components.water_heater
Source: custom_components/thermia/water_heater.py:69
Integration: Water Heater (documentation, issues)
First occurred: 14:27:19 (2 occurrences)
Last logged: 14:27:19
Error adding entities for domain water_heater with platform thermia
Error while setting up thermia platform for water_heater
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 382, in async_add_entities
await asyncio.gather(*tasks)
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 513, in _async_add_entity
capabilities=entity.capability_attributes,
File "/usr/src/homeassistant/homeassistant/components/water_heater/init.py", line 184, in capability_attributes
self.hass, self.min_temp, self.temperature_unit, self.precision
File "/config/custom_components/thermia/water_heater.py", line 69, in min_temp
return self.water_heater.heat_min_temperature_value
File "/usr/local/lib/python3.9/site-packages/ThermiaOnlineAPI/model/HeatPump.py", line 89, in heat_min_temperature_value
return self.__temperature_state.get("minValue")
AttributeError: 'NoneType' object has no attribute 'get'
This is the json retrieved when for URL: https://online-classic-serviceapi.azurewebsites.net/api/v1/installationstatus/MYID/status when I use the webinterface:
{
"hasIndoorTempSensor": false,
"indoorTemperature": 20.000000298023224,
"isOutdoorTempSensorFunctioning": true,
"outdoorTemperature": 13,
"isHotWaterActive": false,
"hotWaterTemperature": -100,
"heatingEffect": 20,
"isHeatingEffectSetByUser": false,
"heatingEffectRegisters": [
null,
1012
],
"reducedHeatingEffect": 19,
"reducedHeatingEffectRegisters": [
null,
1007
],
"isReducedHeatingEffectSetByUser": false,
"programVersion": "1.2.0",
"dcmVersion": "2.0.17",
"linkIntegrationStatus": false,
"roomFactor": 2,
"hotWaterRegistryName": "UI_TAP_WATER",
"isGaugeDifferenciated": false
}
Have been using this for a while and it has worked fine. However a while ago the integration failed. I had to delete the integraton and reinstall it but now I only have one entity: The water heater. What have changed?
I used to see most of the stats on the heat pump.
I log in to the classic api and have a Thermia Diplomat TW6.
What a great effort on this. Got it working on sensors, and pump running times.Total 14 sensors. Did first add custom component, and then integration.
Would it be possible to get also heating curve settings to the integration? To adjust them. These are available on thermia online. I am looking for possibility to automate adjustment of temperatures.
Thanks!
I have two heatpumps in my Thermia genesis account where one of them are a ghost that i can not remove. The ghost heatpump is in offline state with 'isOnline': False. My issue is that the entities of my actual heatpump are not updated except from the initial reading and in addition i get a error message in the CORE system log in HA for each poll cycle.
2022-02-10 18:47:51 ERROR (MainThread) [ThermiaOnlineAPI.model.HeatPump] Error in getting device's temperature status. No temperature register index.
A sugested improvment is that the integration are able to flag to HA that the heatpump is offline.
Thank you for an great integration!
Have been testing the integration for a while but running into problems.
After some time (6 - 24 hours), the integration stops updating values.
If I restart HA it starts updating again
HA
Home Assistant 2022.12.1
Supervisor 2022.11.2
Operating System 9.3
Frontend-version: 20221208.0 - latest
Heat pump
Outside Thermia iTec 9
Inner section Total +60
Thermia Online
Section of the log
2022-12-09 20:56:10.435 WARNING (SyncWorker_1) [homeassistant.loader] We found a custom integration thermia which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2022-12-09 20:56:10.436 WARNING (SyncWorker_1) [homeassistant.loader] We found a custom integration hacs which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2022-12-09 20:57:13.160 WARNING (MainThread) [homeassistant.bootstrap] Waiting on integrations to complete setup: thermia
2022-12-10 00:43:35.777 WARNING (MainThread) [homeassistant.helpers.state] Integration sensor does not support reproduce state
2022-12-10 00:43:35.783 WARNING (MainThread) [homeassistant.components.water_heater.reproduce_state] Invalid state specified for water_heater.klas_jansson: AUTO
2022-12-10 21:58:13.821 WARNING (SyncWorker_3) [ThermiaOnlineAPI.api.ThermiaAPI] Error authenticating with Azure auth.'access_token'
2022-12-10 21:58:13.833 ERROR (MainThread) [custom_components.thermia] Error fetching thermia data: local variable 'result' referenced before assignment
2022-12-10 21:58:23.766 WARNING (SyncWorker_0) [ThermiaOnlineAPI.api.ThermiaAPI] Error authenticating with Azure auth.'access_token'
2022-12-10 21:58:33.755 WARNING (SyncWorker_2) [ThermiaOnlineAPI.api.ThermiaAPI] Error authenticating with Azure auth.'access_token'
2022-12-10 21:58:43.763 WARNING (SyncWorker_0) [ThermiaOnlineAPI.api.ThermiaAPI] Error authenticating with Azure auth.'access_token'
2022-12-10 21:58:53.766 WARNING (SyncWorker_4) [ThermiaOnlineAPI.api.ThermiaAPI] Error authenticating with Azure auth.'access_token'
2022-12-10 21:59:03.769 WARNING (SyncWorker_2) [ThermiaOnlineAPI.api.ThermiaAPI] Error authenticating with Azure auth.'access_token'
2022-12-10 21:59:13.809 WARNING (SyncWorker_0) [ThermiaOnlineAPI.api.ThermiaAPI] Error authenticating with Azure auth.'access_token'
2022-12-10 21:59:23.808 WARNING (SyncWorker_3) [ThermiaOnlineAPI.api.ThermiaAPI] Error authenticating with Azure auth.'access_token'
2022-12-10 21:59:33.755 WARNING (SyncWorker_4) [ThermiaOnlineAPI.api.ThermiaAPI] Error authenticating with Azure auth.'access_token'
And so on.
Please if I can get some help to solve the problem.
Hello. I am new user with a new Caliba Duo just installed. I am able to login to thermia.com but i am not able to login to the integration using the same credentials. Any hints on getting a thermia username that is not an email.
This entity is no longer being provided by the thermia integration. If the entity is no longer in use, delete it in settings.
Thank you for this great integration; measurements and set temp works perfectly.
I'm not getting any changes on statuses on HA. On online thermia they do show correctly; (true or false). On HA they show constant values without changing according to actual pump states:
Compressor status; 1
Brinepump status; 2
Hot water status; 16
Heating status; 32
BR, Jari
The integration stopped working yesterday (26.3) afternoon.
When trying to reload it initializing for a long time and then "Failed to set up" appears.
Has Thermia done some changes to their servers?
I can however log in to https://www.online.thermia.se/ and everything seems fine.
I´m running the latest release V3.3.1 and Home Assistant is updated as well.
Hi there,
Maybe you're already aware,
I noticed that since a day or so HA wasn't showing updates any longer.
It seems that Thermia have altered their domain.
old:
https://www.online-genesis.thermia.se/
new:
https://online.thermia.se/
Kind regards,
Vernon
Hi,
Thank you for all the efforts with integration.
I am seen error in the log after homeassistant restart. Have tried to fix it, but error stays. Finally loads ok after sometime, and works then ok but for some reason errors below are raised to homeassistant.log.
2022-10-08 20:31:11.411 ERROR (MainThread) [homeassistant.helpers.integration_platform] Unexpected error importing thermia/cast.py Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/helpers/integration_platform.py", line 40, in _async_process_single_integration_platform_component platform = integration.get_platform(platform_name) 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 1004, in _find_and_load_unlocked ModuleNotFoundError: No module named 'custom_components.thermia_water_heater.cast' 2022-10-08 20:31:19.481 ERROR (MainThread) [homeassistant.helpers.integration_platform] Unexpected error importing thermia/diagnostics.py Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/helpers/integration_platform.py", line 40, in _async_process_single_integration_platform_component platform = integration.get_platform(platform_name) 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 1004, in _find_and_load_unlocked ModuleNotFoundError: No module named 'custom_components.thermia_water_heater.diagnostics' 2022-10-08 20:31:19.487 ERROR (MainThread) [homeassistant.helpers.integration_platform] Unexpected error importing thermia/recorder.py Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/helpers/integration_platform.py", line 40, in _async_process_single_integration_platform_component platform = integration.get_platform(platform_name) 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 1004, in _find_and_load_unlocked ModuleNotFoundError: No module named 'custom_components.thermia_water_heater.recorder' 2022-10-08 20:31:19.488 ERROR (MainThread) [homeassistant.helpers.integration_platform] Unexpected error importing thermia/logbook.py Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/helpers/integration_platform.py", line 40, in _async_process_single_integration_platform_component platform = integration.get_platform(platform_name) 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 1004, in _find_and_load_unlocked ModuleNotFoundError: No module named 'custom_components.thermia_water_heater.logbook' 2022-10-08 20:31:19.491 ERROR (MainThread) [homeassistant.helpers.integration_platform] Unexpected error importing thermia/media_source.py Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/helpers/integration_platform.py", line 40, in _async_process_single_integration_platform_component platform = integration.get_platform(platform_name) 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 1004, in _find_and_load_unlocked ModuleNotFoundError: No module named 'custom_components.thermia_water_heater.media_source' 2022-10-08 20:31:19.493 ERROR (MainThread) [homeassistant.helpers.integration_platform] Unexpected error importing thermia/system_health.py Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/helpers/integration_platform.py", line 40, in _async_process_single_integration_platform_component platform = integration.get_platform(platform_name) 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 1004, in _find_and_load_unlocked ModuleNotFoundError: No module named 'custom_components.thermia_water_heater.system_health' 2022-10-08 20:31:19.495 ERROR (MainThread) [homeassistant.helpers.integration_platform] Unexpected error importing thermia/group.py Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/helpers/integration_platform.py", line 40, in _async_process_single_integration_platform_component platform = integration.get_platform(platform_name) 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 1004, in _find_and_load_unlocked ModuleNotFoundError: No module named 'custom_components.thermia_water_heater.group'
2022-10-08 20:32:10.772 ERROR (MainThread) [homeassistant.helpers.integration_platform] Unexpected error importing thermia/significant_change.py Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/helpers/integration_platform.py", line 40, in _async_process_single_integration_platform_component platform = integration.get_platform(platform_name) 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 1004, in _find_and_load_unlocked ModuleNotFoundError: No module named 'custom_components.thermia_water_heater.significant_change'
Didnt know where to leave feedback but Fyi i can tell that Calibra duo is working with this integration.
Currently, auxiliary heater values show numbers, not "running/not running" values.
Thank you for such a great integration.
Planning to automate heat pump according to the nordpool hour cost. To do that need to calculate integral, and to do that would need to know pump current status.
Would be good to get following information from the app to be exposed to the home assistant:
Operational Status
Auxiliary heater:
3kW
6kW
9kW
Status:
Compressor status
Brinepump status
Hot water status
Heating status
Integral status
Thanks!
Hi.
Thank you for such a great integration!
Now I can use the "Hot Water Boost" button when there is solar over-production current. I planned to use the Smart Grid - SG contacts from the Termia in the future, but now I can use this integration.
In the Thermia are 2 digital in (EVUSmart Grid 1 and Smart Grid 2).
Both open (0 and 0) give normal position.
0 and 1 = Comfort
1 and 1 = Boost ( I wonder if this is Hot Water Boost ?)
I have the Thermia Calibra Cool 7 BW pump.
Software versie
10.1.5
I'm using V3.1.2 release and core 2023.09.2
For the moment I have also No Operational status.
Regards
renaatdb
I believe this has been an issue for quite some time, but just now came up the log entries:
Logger: homeassistant.components.sensor
Source: components/sensor/__init__.py:593
Integration: Sensor (documentation, issues)
First occurred: September 12, 2023 at 09:04:31 (4 occurrences)
Last logged: 09:30:50
• Error adding entities for domain sensor with platform thermia
• Error while setting up thermia platform for sensor
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 586, in state
numerical_value = int(value)
^^^^^^^^^^
ValueError: invalid literal for int() with base 10: 'RADIATORPUMP'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 589, in state
numerical_value = float(value)
^^^^^^^^^^^^
ValueError: could not convert string to float: 'RADIATORPUMP'
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 507, in async_add_entities
await asyncio.gather(*tasks)
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 752, in _async_add_entity
await entity.add_to_platform_finish()
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1002, in add_to_platform_finish
self.async_write_ha_state()
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 730, in async_write_ha_state
self._async_write_ha_state()
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 830, in _async_write_ha_state
state, attr = self._async_generate_attributes()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 771, in _async_generate_attributes
state = self._stringify_state(available)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 736, in _stringify_state
if (state := self.state) is None:
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 593, in state
raise ValueError(
ValueError: Sensor sensor.karpalo_operational_status has device class 'None', state class 'measurement' unit 'None' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-numeric value: 'RADIATORPUMP' (<class 'str'>)
I get this(2022.2.2)
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 382, in async_add_entities
await asyncio.gather(*tasks)
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 510, in _async_add_entity
entry = entity_registry.async_get_or_create(
File "/usr/src/homeassistant/homeassistant/helpers/entity_registry.py", line 401, in async_get_or_create
entity_category=_convert_to_entity_category(entity_category),
File "/usr/src/homeassistant/homeassistant/helpers/entity_registry.py", line 103, in _convert_to_entity_category
return convert_to_entity_category(value, raise_report=raise_report)
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 220, in convert_to_entity_category
return EntityCategory(value)
File "/usr/local/lib/python3.9/enum.py", line 384, in call
return cls.new(cls, value)
File "/usr/local/lib/python3.9/enum.py", line 702, in new
raise ve_exc
ValueError: 'sensor' is not a valid EntityCategory
Got this warning in the HA log:
WARNING (MainThread) [homeassistant.helpers.frame] Detected integration that called async_setup_platforms instead of awaiting async_forward_entry_setups; this will fail in version 2023.3. Please report issue to the custom integration author for thermia using this method at custom_components/thermia/__init__.py, line 51: hass.config_entries.async_setup_platforms(config_entry, PLATFORMS)
Also got a lot of these, but unsure if it is related or just connection issues:
2023-03-02 08:12:11.795 ERROR (SyncWorker_1) [ThermiaOnlineAPI.api.ThermiaAPI] Error setting register 50 value. 500
2023-03-02 08:12:29.037 ERROR (SyncWorker_3) [ThermiaOnlineAPI.api.ThermiaAPI] Error in getting device's register group: REG_GROUP_OPERATIONAL_STATUS, Status: 500
2023-03-02 08:37:00.481 ERROR (SyncWorker_7) [ThermiaOnlineAPI.model.HeatPump.(myIDxxxx)] Status not available, cannot set temperature
2023-03-02 08:37:38.859 ERROR (SyncWorker_15) [ThermiaOnlineAPI.api.ThermiaAPI] Error fetching device status. 500
2023-03-02 08:37:47.789 WARNING (SyncWorker_15) [urllib3.connectionpool] Connection pool is full, discarding connection: online-classic-serviceapi.azurewebsites.net. Connection pool size: 10
I use the integration as part of my automations so I've downgraded to 2023.2 for now (and it's working fine). Not sure if anyone else have seen similar issues.
Hello Krisjanis,
First of all happy new year :).
I added the outdoor temperature sensor in my fork. But I never ever programmed phyton before, and I do not have any HA programming experience, so I guess I did not a very good job, but it works. (thanks to all your hard work!) anyway, if you want to add it the way I did it, I could create a pull request, else I just wait for your implementation and use my own repo for now.
Thanks again for fixing the stuff for the iTec heat pump. It works like a charm in HA for now.
Wrong integration, this was targeted the thermiagenesis integration. i will close this issue.
Thank you for your great work on this integration. My issue started when I updated my Home assistant to HA2023.11. After this update the climate.heat entity disappeared and the possibility to set the heat target also disappeared.
I tried without success, a reinstall if your integration, with a subsequently re-activation of used entities. Some "feed back info" changed from ON to PLUGGED IN.
Log copy from HA:
Unable to prepare setup for platform thermiagenesis.climate: Platform not found (No module named 'homeassistant.util.temperature').
November 20, 2023 at 21:32:51 – (ERROR) setup.py
Googling tells me that that that module was deprecated a year ago, so I’m guessing it was finally removed in 2023.11.
My Thermia as an Thermia Calibra 12
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.