From 0e8e3e86a053b78048befad8d7c2c38abe2c4514 Mon Sep 17 00:00:00 2001 From: Broque Thomas <26755000+Nezreka@users.noreply.github.com> Date: Sat, 18 Apr 2026 18:55:02 -0700 Subject: [PATCH] Fix Duplicate Detector ignoring 'allow duplicate tracks across albums' MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The Duplicate Detector repair job had its own ignore_cross_album setting that was independent of the global allow_duplicate_tracks setting. When a user enabled 'Allow duplicate tracks across albums', the detector still flagged same-titled tracks on different albums as duplicates. Now respects the global setting — if duplicates are allowed, cross-album matches are always skipped. --- core/repair_jobs/duplicate_detector.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/core/repair_jobs/duplicate_detector.py b/core/repair_jobs/duplicate_detector.py index e67e0d47..7f61e811 100644 --- a/core/repair_jobs/duplicate_detector.py +++ b/core/repair_jobs/duplicate_detector.py @@ -47,6 +47,11 @@ class DuplicateDetectorJob(RepairJob): artist_threshold = float(settings.get('artist_similarity', 0.80)) ignore_cross_album = settings.get('ignore_cross_album', True) + # Respect the global "allow duplicate tracks across albums" setting — + # if the user explicitly allows duplicates across albums, never flag them + if context.config_manager and context.config_manager.get('library.allow_duplicate_tracks', False): + ignore_cross_album = True + # Fetch all tracks with artist/album names via JOIN tracks = [] conn = None