### The problem
I had to reboot HA (was in version 2023.12.3 at the time) aft…er a custom integration change (card-mod)... Since than the Tradfri integration is not loading correctly... I reloaded the previous version of card-mod... no change... I removed the integration and re-enter the data to activate IKEA Tradfri integration on HA but since then, the Tradfri is discovered but no entity is loaded (see logs (debug mode) and error code below)... I upgraded to version 2023.12.4... still same issue... Maybe a change in firmware on the tradfri itself ?...
### What version of Home Assistant Core has the issue?
2023.12.4
### What was the last working version of Home Assistant Core?
2023.12.3
### What type of installation are you running?
Home Assistant OS
### Integration causing the issue
IKEA Tradfri
### Link to integration documentation on our website
https://www.home-assistant.io/integrations/tradfri/
### Diagnostics information
{
"home_assistant": {
"installation_type": "Home Assistant OS",
"version": "2023.12.4",
"dev": false,
"hassio": true,
"virtualenv": false,
"python_version": "3.11.6",
"docker": true,
"arch": "x86_64",
"timezone": "Europe/Brussels",
"os_name": "Linux",
"os_version": "6.1.63-haos",
"supervisor": "2023.12.0",
"host_os": "Home Assistant OS 11.2",
"docker_version": "24.0.7",
"chassis": "vm",
"run_as_root": true
},
"custom_components": {
"aquatemp": {
"version": "2.1",
"requirements": []
},
"aqua_temp": {
"version": "3.0.26",
"requirements": []
},
"auto_backup": {
"version": "1.4.1",
"requirements": []
},
"meross_lan": {
"version": "4.5.0-beta.0",
"requirements": []
},
"philips_airpurifier_coap": {
"version": "0.10.8",
"requirements": [
"aioairctrl==0.2.4"
]
},
"remote_homeassistant": {
"version": "3.11",
"requirements": []
},
"watchman": {
"version": "0.5.1",
"requirements": [
"prettytable==3.0.0"
]
},
"average": {
"version": "2.3.1",
"requirements": [
"colorlog==6.7.0"
]
},
"hacs": {
"version": "1.33.0",
"requirements": [
"aiogithubapi>=22.10.1"
]
},
"localtuya": {
"version": "5.2.1",
"requirements": []
},
"sonoff": {
"version": "3.5.2",
"requirements": [
"pycryptodome>=3.6.6"
]
},
"browser_mod": {
"version": "2.3.0",
"requirements": []
}
},
"integration_manifest": {
"domain": "tradfri",
"name": "IKEA TR\u00c5DFRI",
"codeowners": [],
"config_flow": true,
"documentation": "https://www.home-assistant.io/integrations/tradfri",
"homekit": {
"models": [
"TRADFRI"
]
},
"iot_class": "local_polling",
"loggers": [
"pytradfri"
],
"requirements": [
"pytradfri[async]==9.0.1"
],
"is_built_in": true
},
"data": {
"gateway_version": "1.21.31",
"device_data": [
"TRADFRI Driver 30W",
"TRADFRI Driver 30W",
"TRADFRI motion sensor",
"TRADFRI on/off switch",
"TRADFRI on/off switch"
]
}
}
### Example YAML snippet
_No response_
### Anything in the logs that might be useful for us?
```txt
2023-12-27 16:12:01.700 DEBUG (MainThread) [homeassistant.components.tradfri] Manually updated Update coordinator for <65538 - TRADFRI on/off switch 2 (TRADFRI on/off switch)> data
2023-12-27 16:12:01.700 DEBUG (MainThread) [homeassistant.components.tradfri] Finished fetching Update coordinator for <65538 - TRADFRI on/off switch 2 (TRADFRI on/off switch)> data in 0.008 seconds (success: True)
2023-12-27 16:12:01.704 DEBUG (MainThread) [homeassistant.components.tradfri] Manually updated Update coordinator for <65549 - TRADFRI motion sensor (TRADFRI motion sensor)> data
2023-12-27 16:12:01.704 DEBUG (MainThread) [homeassistant.components.tradfri] Finished fetching Update coordinator for <65549 - TRADFRI motion sensor (TRADFRI motion sensor)> data in 0.004 seconds (success: True)
2023-12-27 16:12:01.709 DEBUG (MainThread) [homeassistant.components.tradfri] Manually updated Update coordinator for <65542 - TRADFRI driver 2 (TRADFRI Driver 30W)> data
2023-12-27 16:12:01.710 DEBUG (MainThread) [homeassistant.components.tradfri] Finished fetching Update coordinator for <65542 - TRADFRI driver 2 (TRADFRI Driver 30W)> data in 0.005 seconds (success: True)
2023-12-27 16:12:01.715 DEBUG (MainThread) [homeassistant.components.tradfri] Manually updated Update coordinator for <65547 - TRADFRI driver 3 (TRADFRI Driver 30W)> data
2023-12-27 16:12:01.715 DEBUG (MainThread) [homeassistant.components.tradfri] Finished fetching Update coordinator for <65547 - TRADFRI driver 3 (TRADFRI Driver 30W)> data in 0.006 seconds (success: True)
2023-12-27 16:12:01.776 DEBUG (MainThread) [homeassistant.components.tradfri] Manually updated Update coordinator for <65545 - TRADFRI on/off switch 3 (TRADFRI on/off switch)> data
2023-12-27 16:12:01.776 DEBUG (MainThread) [homeassistant.components.tradfri] Finished fetching Update coordinator for <65545 - TRADFRI on/off switch 3 (TRADFRI on/off switch)> data in 0.061 seconds (success: True)
2023-12-27 16:12:02.622 WARNING (MainThread) [py.warnings] /usr/src/homeassistant/homeassistant/helpers/entity_platform.py:497: RuntimeWarning: coroutine 'EntityPlatform._async_add_entity' was never awaited
tasks = [
2023-12-27 16:12:02.673 ERROR (MainThread) [homeassistant] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 497, in async_add_entities
tasks = [
^
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 497, in <listcomp>
tasks = [
^
File "/usr/src/homeassistant/homeassistant/components/tradfri/light.py", line 39, in <genexpr>
TradfriLight(
File "/usr/src/homeassistant/homeassistant/components/tradfri/light.py", line 62, in __init__
super().__init__(
File "/usr/src/homeassistant/homeassistant/components/tradfri/base_class.py", line 64, in __init__
sw_version=info.firmware_version,
^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/pytradfri/device/__init__.py", line 177, in firmware_version
return self.raw[ATTR_DEVICE_FIRMWARE_VERSION]
~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
KeyError: '3'
2023-12-27 16:12:02.677 ERROR (MainThread) [homeassistant.components.sensor] Error while setting up tradfri platform for sensor
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 361, in _async_setup_platform
await asyncio.shield(task)
File "/usr/src/homeassistant/homeassistant/components/tradfri/sensor.py", line 171, in async_setup_entry
TradfriSensor(
File "/usr/src/homeassistant/homeassistant/components/tradfri/sensor.py", line 195, in __init__
super().__init__(
File "/usr/src/homeassistant/homeassistant/components/tradfri/base_class.py", line 64, in __init__
sw_version=info.firmware_version,
^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/pytradfri/device/__init__.py", line 177, in firmware_version
return self.raw[ATTR_DEVICE_FIRMWARE_VERSION]
~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
KeyError: '3'
```
### Additional information
_No response_