From 2b498a779d8a5b82be7a3b9ed7ffb61ed393c481 Mon Sep 17 00:00:00 2001 From: Ji Hwan Date: Mon, 25 Nov 2024 10:18:19 +0900 Subject: [PATCH] fix: monitor stuck on wait when closing Signed-off-by: Ji Hwan --- cmd/monitor/monitor.go | 4 ---- 1 file changed, 4 deletions(-) diff --git a/cmd/monitor/monitor.go b/cmd/monitor/monitor.go index e12ea476..7b037952 100644 --- a/cmd/monitor/monitor.go +++ b/cmd/monitor/monitor.go @@ -193,14 +193,10 @@ func monitor(ctx context.Context) error { } }() - // Give time for the UI to attempt rendering. - time.Sleep(5 * time.Second) if !isUiRendered { // If UI cannot be rendered and returns, close the goroutine. ctx.Done() } - // Give time for goroutine to finish. - time.Sleep(1 * time.Second) // Receive the errors from errChan and return to exit. err = <-errChan return err