server recommend restart on package updates

Signed-off-by: Vladimir Mandic <mandic00@live.com>
This commit is contained in:
Vladimir Mandic
2025-09-18 12:05:56 -04:00
parent 5606519085
commit f971550bfb
3 changed files with 7 additions and 0 deletions
+1
View File
@@ -15,6 +15,7 @@
it also does not work with control and video tabs which are the core of sdnext nowadays
so it has been removed from built-in extensions: manual installation is still possible
- **Other**
- server will note when restart is recommended due to package updates
- **logging** enable `debug`, `docs` and `api-docs` by default
- **ipex** simplify internal implementation
- refactor to use new libraries
+3
View File
@@ -56,6 +56,7 @@ args = Dot({
})
git_commit = "unknown"
diffusers_commit = "unknown"
restart_required = False
extensions_commit = { # force specific commit for extensions
'sd-webui-controlnet': 'ecd33eb',
'adetailer': 'a89c01d'
@@ -345,6 +346,8 @@ def installed(package, friendly: str = None, reload = False, quiet = False): # p
log.warning(f'Install: package="{p[0]}" installed={pkg_version} required={p[1]} allowing experimental')
else:
log.warning(f'Install: package="{p[0]}" installed={pkg_version} required={p[1]} version mismatch')
global restart_required # pylint: disable=global-statement
restart_required = True
ok = ok and (exact or args.experimental)
else:
if not quiet:
+3
View File
@@ -297,6 +297,9 @@ def main():
installer.log.info(f'Installer time: {init_summary()}')
get_custom_args()
if installer.restart_required:
installer.log.warning('Restart is recommended due to packages updates...')
uv, instance = start_server(immediate=True, server=None)
t_server = time.time()
t_monitor = time.time()