PimDoos / onesmartcontrolha

Home Assisttant integration for One Smart Control server
Apache License 2.0
4 stars 1 forks source link

Custom integration errors after first install #36

Closed kababoom closed 1 year ago

kababoom commented 1 year ago

First of all thank you for creating this repo, really exited about adding our onesmartcontrol house to homeassistant ....

I have added the 0.30 version in HACS, created a separate userid in smartcontrol, added the integration in HA and used the newly created username and password. Without any authentication errors after adding there are no devices and no entities. The HA logging shows the following:

Error while setting up onesmartcontrol platform for switch 11:00:42 PM – (ERROR) Switch (custom integration) Error while setting up onesmartcontrol platform for water_heater 11:00:42 PM – (ERROR) Water Heater (custom integration) Error while setting up onesmartcontrol platform for climate 11:00:42 PM – (ERROR) Climate (custom integration) Error while setting up onesmartcontrol platform for sensor 11:00:42 PM – (ERROR) Sensor (custom integration)

Details of the first one:

Logger: homeassistant.components.sensor Source: custom_components/onesmartcontrol/onesmartentity.py:31 Integration: Sensor (documentation, issues) First occurred: 11:00:42 PM (1 occurrences) Last logged: 11:00:42 PM

Error while setting up onesmartcontrol platform for sensor Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 281, in _async_setup_platform await asyncio.shield(task) File "/config/custom_components/onesmartcontrol/sensor.py", line 92, in async_setup_entry OneSmartSensor( File "/config/custom_components/onesmartcontrol/sensor.py", line 127, in init super().init(hass, config_entry, wrapper, update_topic, source, device_id, name, suffix, icon) File "/config/custom_components/onesmartcontrol/onesmartentity.py", line 31, in init self._room = rooms[self._device[OneSmartFieldName.ROOM]] KeyError: ''

Any idea of what I might have done wrong?

PimDoos commented 1 year ago

Hmm, interesting... Do you have any rooms setup in the app?

PimDoos commented 1 year ago

Might be fixed with #37. Will be in release v0.3.1. Let me know if it works.

kababoom commented 1 year ago

Working, thanks....