home-assistant / core

:house_with_garden: Open source home automation that puts local control and privacy first.
https://www.home-assistant.io
Apache License 2.0
72.82k stars 30.51k forks source link

Error while setting up luftdaten platform for sensor #42302

Closed FlavorFx closed 4 years ago

FlavorFx commented 4 years ago

Luftdaten Sensor setup failed

Environment

Problem-relevant configuration.yaml

Traceback/Error logs

Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 201, in _async_setup_platform
    await asyncio.gather(*pending)
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 310, in async_add_entities
    await asyncio.gather(*tasks)
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 356, in _async_add_entity
    if entity.unique_id is not None:
  File "/usr/src/homeassistant/homeassistant/components/luftdaten/sensor.py", line 88, in unique_id
    return f"{self._data['sensor_id']}_{self.sensor_type}"
KeyError: 'sensor_id'

Additional information

probot-home-assistant[bot] commented 4 years ago

Hey there @fabaff, mind taking a look at this issue as its been labeled with an integration (luftdaten) you are listed as a codeowner for? Thanks! (message by CodeOwnersMention)

springstan commented 4 years ago

Duplicate of #36825