It is not possible to add two Air Fryers at the same time with this integration. We have two air fryers in the house. One we use for our Gluten Intolerant son and the other one is our main one. It is fine when you add one of the air fryers, but which ever air fryer you add secodns has all sensors as Unknown. I tried adding one air fryer then the other and in reverse order and the result was the same. The fryer you add first works fine always but the second one never works.
Maybe related to this:
Logger: homeassistant.components.switch
Source: helpers/entity_platform.py:366
integration: Switch ([documentation](https://www.home-assistant.io/integrations/switch), [issues](https://github.com/home-assistant/core/issues?q=is%3Aissue+is%3Aopen+label%3A%22integration%3A+switch%22))
First occurred: 16:55:22 (2 occurrences)
Last logged: 16:55:35
Error while setting up xiaomi_airfryer platform for switch
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 366, in _async_setup_platform
await asyncio.shield(awaitable)
File "/config/custom_components/xiaomi_airfryer/switch.py", line 180, in async_setup_entry
hass.data[DATA_KEY][host][DATA_DEVICE] = device
~~~~~~~~~~~~~~~~~~~^^^^^^
KeyError: '192.168.2.141'
Logger: homeassistant.helpers.entity
Source: helpers/entity.py:960
First occurred: 16:55:32 (170 occurrences)
Last logged: 16:58:15
Update for sensor.xiaomi_airfryer_apponit_time_2 fails
Update for sensor.xiaomi_airfryer_food_quanty_2 fails
Update for sensor.xiaomi_airfryer_preheat_phase_2 fails
Update for sensor.xiaomi_airfryer_appoint_time_left_2 fails
Update for sensor.xiaomi_airfryer_turn_pot_2 fails
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 960, in async_update_ha_state
await self.async_device_update()
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1318, in async_device_update
await self.async_update()
File "/config/custom_components/xiaomi_airfryer/sensor.py", line 214, in async_update
state = self.hass.data[DATA_KEY][self._host].get(DATA_STATE, None)
~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^
KeyError: '192.168.2.141'
It is not possible to add two Air Fryers at the same time with this integration. We have two air fryers in the house. One we use for our Gluten Intolerant son and the other one is our main one. It is fine when you add one of the air fryers, but which ever air fryer you add secodns has all sensors as Unknown. I tried adding one air fryer then the other and in reverse order and the result was the same. The fryer you add first works fine always but the second one never works.
Maybe related to this: