From 5d3a93f10315b14558f03a74c9c69432248e58d8 Mon Sep 17 00:00:00 2001 From: yusing Date: Tue, 21 Jan 2025 10:37:09 +0800 Subject: [PATCH] idlewatcher: fix visiting unhealthy idle watched container causes panic --- internal/docker/idlewatcher/watcher.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/docker/idlewatcher/watcher.go b/internal/docker/idlewatcher/watcher.go index 16cdf0f1..f0860d11 100644 --- a/internal/docker/idlewatcher/watcher.go +++ b/internal/docker/idlewatcher/watcher.go @@ -180,7 +180,7 @@ func (w *Watcher) wakeIfStopped() error { case "running": return nil default: - panic(errShouldNotReachHere) + return E.Errorf("unexpected container status: %s", status) } }