From a33cca6033fd72c307489481a4b316def4348754 Mon Sep 17 00:00:00 2001 From: Gykes <24581046+Gykes@users.noreply.github.com> Date: Wed, 22 Apr 2026 21:57:53 -0700 Subject: [PATCH] Fix: Release DB Lock on Large Image Libraries (#6845) --- internal/manager/task_generate.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/internal/manager/task_generate.go b/internal/manager/task_generate.go index f2aab2b3c..6f8ac8178 100644 --- a/internal/manager/task_generate.go +++ b/internal/manager/task_generate.go @@ -262,7 +262,9 @@ func (j *GenerateJob) Execute(ctx context.Context, progress *job.Progress) error for f := range queue { if job.IsCancelled(ctx) { - break + // keep draining the queue so the producer goroutine can finish + // and release its read transaction, otherwise the DB stays locked + continue } wg.Add()