genielabs / HomeGenie

HomeGenie, the programmable automation intelligence
https://homegenie.it
GNU General Public License v3.0
388 stars 155 forks source link

User backup restores throws errors #339

Closed tuicemen closed 5 years ago

tuicemen commented 5 years ago

I never noticed this prior to HG 1.2 but maybe because I'm a bit more conscious of things now. theses errors don't seem to affect HG nor the user created programs other then they need to be restarted. These errors pop up and disappear so quickly it is hard to catch exactly what they are showing.

Does this info get saved to a log file? Or can we pause the restore process to read this info? I know one error is about depreciated code suggesting to use another method but other disappears before I get a chance to read it. I also don't know to what these refer to so if these are logged knowing where to look will help as might a Pause in the restore function.

genemars commented 5 years ago

Some methods of HG API have been marked as deprecated and they might be removed with future updates. This is only a warning message due to the fact that some C# programs from the HG package repository (or user's programs) are still using some of those deprecated methods. This message is only shown once a program is being imported or compiled.

tuicemen commented 5 years ago

OK thanks, I didn't remember seeing the message before running the 1.2 betas They should be labelled "Warning" not as an "Error" as that makes users think there is an issue with the HG restore and something is going to fail. This may result in users reverting back to an older version or moving on to something else.

genemars commented 5 years ago

If it says "error" then it must be something else. I'm just pushing a new release that has a fix to the program import/install functionality. Maybe it's related.

tuicemen commented 5 years ago

I'll move to it as soon as HG sees it as an update and report back.

tuicemen commented 5 years ago

OK HG updated to 1.2 beta11.

the only issue I had was my user created programs didn't auto start I had to go into configuration and Enable them. these are programs that are not listed in the package manager. One is from the Old HG forum (email cam pictures) and two I created one based from the email pictures and one based off the Philips hue program to use HA-Bridge. Once the programs are enabled they stay running, a HG update or backup restore disables them.

genemars commented 5 years ago

A backup restore can disable user programs if the backup was made when the programs were disabled, but the update manager shouldn't disable user programs after an update. I'll check this out.

tuicemen commented 5 years ago

I realize that but the backup was made with all three user programs enabled. I'll make a fresh backup and test with this version.

tuicemen commented 5 years ago

Ok backed up and restored from beta 11 the Error message now shows as a warning. However the for mentioned programs still are restored disabled. These are c sharp programs so I suspect these are also what are throwing the obsolete code messages when restoring. Maybe the obsolete code warning is disabling?

genemars commented 5 years ago

Thanks to your report I was able to reproduce the issue and fix it. The update will be shortly available.

tuicemen commented 5 years ago

Awesome! updating Now. Great work with HG!