You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi,
first of all - thank you for providing this component!!
As I was trying to activate this component, I found an issue that should be easily resolvable :)
If the Name of the scooter contains whitespaces or includes capital letters, you get the error below. So if you would implement x.lower and maybe replace whitespaces, this should be it.
Log:
2020-08-23 21:06:30 ERROR (MainThread) [homeassistant.components.sensor] Error while setting up niu platform for sensor
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 192, in _async_setup_platform
await asyncio.gather(*pending)
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 301, in async_add_entities
await asyncio.gather(*tasks)
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 443, in _async_add_entity
raise HomeAssistantError(f"Invalid entity id: {entity.entity_id}")
homeassistant.exceptions.HomeAssistantError: Invalid entity id: sensor.niu_scooter_NAME_battery_charge
Thanks!
The text was updated successfully, but these errors were encountered:
Hi,
first of all - thank you for providing this component!!
As I was trying to activate this component, I found an issue that should be easily resolvable :)
If the Name of the scooter contains whitespaces or includes capital letters, you get the error below. So if you would implement x.lower and maybe replace whitespaces, this should be it.
Log:
2020-08-23 21:06:30 ERROR (MainThread) [homeassistant.components.sensor] Error while setting up niu platform for sensor
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 192, in _async_setup_platform
await asyncio.gather(*pending)
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 301, in async_add_entities
await asyncio.gather(*tasks)
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 443, in _async_add_entity
raise HomeAssistantError(f"Invalid entity id: {entity.entity_id}")
homeassistant.exceptions.HomeAssistantError: Invalid entity id: sensor.niu_scooter_NAME_battery_charge
Thanks!
The text was updated successfully, but these errors were encountered: