See here
https://github.com/HelloZeroNet/ZeroNet/blob/py3/zeronet.py#L34-L47
It is restarting after the update. Is this step mandatory to complete the update? Would it be possible to have an option which let us control if not we want to restart the ZeroNet?
Restating ZeroNet is needed to apply all changes (changed modules, removed modules, new modules, changed plugins...) to Python runtime environment.
Reloading changes without restart might be possible but it would require manual reloading of modules using some Python functions. But I don't know how stable would it work.
Actually, is restarting ZeroNet a problem?
Actually, is restarting ZeroNet a problem?
I am using ZeroNet embeded in an application and it is starting a second instance of the application after the update.
I have created a plugin to have a bit more control over it and noticed that the option exist in the code but hasn't been used. If we could have a "update and shutdown" option that would help.
If you have better approaches to solve this that would be nice. I am just trying to asses the solutions right now.
This PR has the code changes that I had in mind : https://github.com/HelloZeroNet/ZeroNet/pull/2242
Can somebody close this since relevant changes were merged?
Most helpful comment
I am using ZeroNet embeded in an application and it is starting a second instance of the application after the update.
I have created a plugin to have a bit more control over it and noticed that the option exist in the code but hasn't been used. If we could have a "update and shutdown" option that would help.
If you have better approaches to solve this that would be nice. I am just trying to asses the solutions right now.
This PR has the code changes that I had in mind : https://github.com/HelloZeroNet/ZeroNet/pull/2242