ui: restart if crash (#36746)

* simpler

* mypy your are going to be replaced very soon
This commit is contained in:
Maxime Desroches
2025-12-01 22:55:14 -08:00
committed by GitHub
parent cabfa7b735
commit fa18bb9261

View File

@@ -155,6 +155,10 @@ def manager_thread() -> None:
print(running)
cloudlog.debug(running)
if 'ui' in managed_processes and managed_processes['ui'].proc is not None and not managed_processes['ui'].proc.is_alive():
cloudlog.error(f'Restarting UI (exitcode {managed_processes["ui"].proc.exitcode})')
managed_processes['ui'].restart()
# send managerState
msg = messaging.new_message('managerState', valid=True)
msg.managerState.processes = [p.get_process_state_msg() for p in managed_processes.values()]