Closed PhilippMundhenk closed 1 year ago
Thanks @PhilippMundhenk I will take a look at this soon 👍
Take your time! I have to admit it is not the nicest code I have ever written, but it does the job.
I did find a bit more time and also added the attributes suggested in #29, might actually be helpful:
Not sure if I am handling the HA entity management correctly though. My first time working on a custom component. If you have the time, some extra scrutiny would be appreciated, esp. around sensor setup, naming, etc.
Marking this as draft, will have to fix the sensor naming: Currently, only a single UK instance can be configured, as hard-coded sensor naming of sensor.uptimekuma clashes...
LGTM 👍
Any reason why the _INFO
dictionaries include a decimal 0
? It seems like the decimal will never change?
This functionality is great. Thank you for implementing it.
LGTM 👍 Any reason why the
_INFO
dictionaries include a decimal0
? It seems like the decimal will never change?
I think I just copy & paated the existing infos. Tried to keep the same style. No reason from my side.
as discussed in https://github.com/meichthys/uptime_kuma/issues/29 (though much smaller scope)
Summary sensors are possible in Home Assistant, but flexible groups with wildcards require additional custom components, or significant templating. A simple sensor that automatically considers all uptime kuma instances without additional configuration is helpful.
Implementation is simple enough, but yes, maintenance might be required in future. I will support if I can, but I leave the decision to integrate this to @meichthys.