From 400fa6d77b416070c19cf5615a747ac53aece413 Mon Sep 17 00:00:00 2001 From: Adil Hafeez Date: Thu, 15 May 2025 11:31:22 -0700 Subject: [PATCH] add more logs --- arch/tools/cli/core.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/arch/tools/cli/core.py b/arch/tools/cli/core.py index c32d16c2..72539d0f 100644 --- a/arch/tools/cli/core.py +++ b/arch/tools/cli/core.py @@ -94,10 +94,15 @@ def start_arch(arch_config_file, env, log_timeout=120, foreground=False): current_time = time.time() elapsed_time = current_time - start_time + if archgw_status == "exited": + log.info("archgw container exited unexpectedly.") + stream_gateway_logs(follow=False) + sys.exit(1) + # Check if timeout is reached if elapsed_time > log_timeout: log.info(f"stopping log monitoring after {log_timeout} seconds.") - break + sys.exit(1) if prompt_gateway_health_check_status or llm_gateway_health_check_status: log.info("archgw is running and is healthy!")