From c2d7ae773c37d1a8ad0e620fe9051ae35edf9b18 Mon Sep 17 00:00:00 2001 From: Deluan Date: Wed, 22 Jul 2026 23:46:31 -0400 Subject: [PATCH] chore(artwork): generic 500 bodies on refresh endpoint, trim stale test comments --- core/artwork/e2e/e2e_suite_test.go | 7 +++---- server/nativeapi/artwork.go | 4 ++-- server/subsonic/e2e/subsonic_artwork_test.go | 3 +-- 3 files changed, 6 insertions(+), 8 deletions(-) diff --git a/core/artwork/e2e/e2e_suite_test.go b/core/artwork/e2e/e2e_suite_test.go index 15b3eb6e9..bec7b12cf 100644 --- a/core/artwork/e2e/e2e_suite_test.go +++ b/core/artwork/e2e/e2e_suite_test.go @@ -1,7 +1,6 @@ -// Package e2e exercises the artwork pipeline end to end against the NEW acquisition→serve -// path: it enqueues real entities, drives the real Worker to drain the queue, and serves the -// result through the real Service, over a real ImageStore and real library files. It replaces -// the legacy core/artwork/e2e suite that was removed with the old readers in the serving cutover. +// Package e2e exercises the artwork pipeline end to end: it enqueues real entities, drives the +// real Worker to drain the queue, and serves the result through the real Service, over a real +// ImageStore and real library files. package e2e import ( diff --git a/server/nativeapi/artwork.go b/server/nativeapi/artwork.go index cefbccff4..0a07014be 100644 --- a/server/nativeapi/artwork.go +++ b/server/nativeapi/artwork.go @@ -34,14 +34,14 @@ func (api *Router) refreshArtwork() http.HandlerFunc { } if err := api.ds.Artwork(ctx).DeleteForItem(kind, id); err != nil { log.Error(ctx, "Error clearing artwork state", "kind", kind, "id", id, err) - http.Error(w, err.Error(), http.StatusInternalServerError) + http.Error(w, http.StatusText(http.StatusInternalServerError), http.StatusInternalServerError) return } item := model.ArtworkQueueItem{ItemKind: kind, ItemID: id, ImageType: model.ImageTypePrimary, Priority: model.ArtworkPriorityBump} if err := api.ds.ArtworkQueue(ctx).Enqueue(item); err != nil { log.Error(ctx, "Error enqueuing artwork refresh", "kind", kind, "id", id, err) - http.Error(w, err.Error(), http.StatusInternalServerError) + http.Error(w, http.StatusText(http.StatusInternalServerError), http.StatusInternalServerError) return } w.WriteHeader(http.StatusNoContent) diff --git a/server/subsonic/e2e/subsonic_artwork_test.go b/server/subsonic/e2e/subsonic_artwork_test.go index 4023ad03e..fc4bec8a0 100644 --- a/server/subsonic/e2e/subsonic_artwork_test.go +++ b/server/subsonic/e2e/subsonic_artwork_test.go @@ -45,8 +45,7 @@ import ( // The artwork serving path streams folder-backed originals via os.Open, which a fake FS cannot // back, so this suite scans a small REAL on-disk library and drives the real acquisition worker -// and artwork.Service through the Subsonic and public image handlers. It restores the Task 11 -// full-pipeline coverage (album found/absent + suffix transition + share/img) against the new path. +// and artwork.Service through the Subsonic and public image handlers. var _ = Describe("Artwork Serving", Ordered, func() { var ( artRouter *subsonic.Router