BenPru / luxtronik

Luxtronik integration for Home Assistant
MIT License
66 stars 23 forks source link

Test Version Migration from 2023.03.24 #164

Open BenPru opened 8 months ago

BenPru commented 8 months ago
Legacy Name New Name Luxtronik Key Comment
climate.domestic_water water_heater.domestic_water Losing historical data!!!
number.*
domestic_water_target_temperature dhw_target_temperature 0002 parameters.ID_Einst_BWS_akt
domestic_water_hysteresis dhw_hysteresis 0074 parameters.ID_Einst_BWS_Hyst_akt
domestic_water_thermal_desinfection_target dhw_thermal_desinfection_target 0047 parameters.ID_Einst_LGST_akt
cooling_target_temperature cooling_target_temperature_mk1 / cooling_target_temperature_mk2 / cooling_target_temperature_mk3
sensor.*
domestic_water_temperature dhw_temperature 0017 calculations.ID_WEB_Temperatur_TBW
operation_hours_domestic_water dhw_operation_hours 0065 calculations.ID_WEB_Zaehler_BetrZeitBW
heat_amount_domestic_water dhw_heat_amount 0152 calculations.ID_WEB_WMZ_Brauchwasser
domestic_water_energy_input dhw_energy_input 1137 parameters.Unknown_Parameter_1137
compressor_impulses compressor1_impulses 0057 calculations.ID_WEB_Zaehler_BetrZeitImpVD1 unit_of_measurement: Anzahl -> ∑
compressor_impulses2 compressor2_impulses 0059 calculations.ID_WEB_Zaehler_BetrZeitImpVD2
operation_hours_compressor1 compressor1_operation_hours 0056 calculations.ID_WEB_Zaehler_BetrZeitVD1
operation_hours_compressor2 compressor2_operation_hours 0058 calculations.ID_WEB_Zaehler_BetrZeitVD2
operation_hours_additional_heat_generator additional_heat_generator_operation_hours 0060 calculations.ID_WEB_Zaehler_BetrZeitZWE1
room_temperature roomthermostattemperature 0227 calculations.ID_WEB_RBE_RT_Ist
room_target_temperature room_thermostat_temperature_target 0228 calculations.ID_WEB_RBE_RT_Soll
binary_sensor.*
domestic_water_recirculation_pump dhw_recirculation_pump 0038 calculations.ID_WEB_BUPout
domestic_water_circulation_pump dhw_circulation_pump 0046 calculations.ID_WEB_ZIPout
domestic_water_charging_pump dhw_charging_pump 0046 calculations.ID_WEB_ZIPout
Kars-de-Jong commented 8 months ago

@BenPru I tested a migration from version 2023.9.10 to 2023.10.16-Beta on my Home Assistant test instance, which has no access to the heatpump. It failed, with the following relevant log entries:

2023-10-25 12:49:23.865 ERROR (MainThread) [homeassistant.config_entries] Error migrating entry Alpha Innotec MSW2-6S 311111-0729 for luxtronik2
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/config_entries.py", line 658, in async_migrate
result = await component.async_migrate_entry(hass, self)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/config/custom_components/luxtronik2/__init__.py", line 87, in async_migrate_entry
await _async_delete_legacy_devices(hass, config_entry)
File "/config/custom_components/luxtronik2/__init__.py", line 274, in _async_delete_legacy_devices
coordinator = LuxtronikCoordinator.connect(hass, config_entry)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/config/custom_components/luxtronik2/coordinator.py", line 206, in connect
client = Luxtronik(
^^^^^^^^^^
File "/config/custom_components/luxtronik2/lux_helper.py", line 188, in __init__
self.read()
File "/config/custom_components/luxtronik2/lux_helper.py", line 202, in read
self._read_write(write=False)
File "/config/custom_components/luxtronik2/lux_helper.py", line 218, in _read_write
self._socket.connect((self._host, self._port))
TimeoutError: [Errno 110] Operation timed out

After that, another error was logged:

2023-10-25 12:49:23.870 ERROR (MainThread) [custom_components.luxtronik2] Unexpected exception when checking if a socket is closed
Traceback (most recent call last):
File "/config/custom_components/luxtronik2/lux_helper.py", line 150, in _is_socket_closed
data = sock.recv(16, socket.MSG_DONTWAIT | socket.MSG_PEEK)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
OSError: [Errno 107] Socket not connected
BenPru commented 8 months ago

which has no access to the heatpump. It failed

Yes, the migration need a connection to the heatpump to detect the devices. Without connection the migration can not run successfull.

Taijian commented 7 months ago

I just did an upgrade to the latest beta - seems to work flawlessly. Even notified me of a firmware update on startup.