IoTuring icon indicating copy to clipboard operation
IoTuring copied to clipboard

AppInfo Enhancements

Open infeeeee opened this issue 2 years ago • 7 comments

Some enhancement ideas about AppInfo entity

  • Make configurable that AppInfo Name and Appinfo Version show up as one sensor
  • For update checking, if IoTuring is installed via git, compare git commit hashes instead of version from pypi.

infeeeee avatar Jan 12 '24 13:01 infeeeee

Yes correct, if install by git we could check in that way. For AppInfo, do you mean avoid having multiple entities for those two information ?

richibrics avatar Feb 12 '24 17:02 richibrics

Appinfo shows up as 3 sensors in HA: Name, Update and Version. Name and Version could be merged as one, where version is just an extra attribute, or something like that. I was thinking maybe 3 sensors for this is a bit overkill, and they most of the time just static data. I think they were created before extra attributes.

infeeeee avatar Feb 12 '24 17:02 infeeeee

Would it be better to have the version in the Name or in the Update ? I think the name would have sense to store app information as extra, but the Update is directly related to the version update so it would be good also there.

richibrics avatar Feb 12 '24 17:02 richibrics

An enhancement would also to update the app using a command, so to create an Update entity in Hass

richibrics avatar Feb 12 '24 17:02 richibrics

Would it be better to have the version in the Name or in the Update ?

I don't know, this was just an idea to declutter a bit, whatever looks better. maybe in the Name, or both? I just wanted to write this down so it won't be forgotten.

An enhancement would also to update the app using a command, so to create an Update entity in Hass

Yes, that would be awesome. But it would need a lot more work, some code for detecting install method, and how IoTuring is run to restart it. Or maybe auto update should only work if autostart is set up from configuration? So this should be implemented after #39

infeeeee avatar Feb 12 '24 17:02 infeeeee

If I'm not wrong Python allows to know the command that started the script, and the script should already have the permissions to start itself again with the same permissions so I would leave it separated from the autostart thing

richibrics avatar Feb 12 '24 19:02 richibrics

I'll start with AppInfo changes

richibrics avatar Feb 12 '24 20:02 richibrics