From a101ff3cc9653825dea32c0e315197b571fe116b Mon Sep 17 00:00:00 2001 From: Eli Ribble Date: Tue, 28 Apr 2026 22:24:15 +0000 Subject: [PATCH] Suppress errors from canceled context on DB notification goroutine --- platform/start.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/platform/start.go b/platform/start.go index a008e687..3762d455 100644 --- a/platform/start.go +++ b/platform/start.go @@ -166,6 +166,10 @@ func listenAndDoOneJob(ctx context.Context) error { notification, err := conn.Conn().WaitForNotification(ctx) if err != nil { //if !pgconn.Timeout(err) { + if err2 := ctx.Err(); err2 != nil { + log.Info().Err(err2).Msg("DB notification context err") + return nil + } return fmt.Errorf("failed while waiting for notification of new job: %w", err) }