Skip to content

refactor: consolidate artist filtering with allow_compilations parameter#46

Merged
jakebromberg merged 2 commits intomainfrom
refactor/consolidate-artist-filtering
Feb 22, 2026
Merged

refactor: consolidate artist filtering with allow_compilations parameter#46
jakebromberg merged 2 commits intomainfrom
refactor/consolidate-artist-filtering

Conversation

@jakebromberg
Copy link
Member

@jakebromberg jakebromberg commented Feb 22, 2026

Summary

  • Add allow_compilations parameter to matches_artist_or_compilation()
  • Rewrite filter_results_by_artist to use the utility (with allow_compilations=False)
  • Replace inline filter in _discogs_cross_reference with utility call
  • Replace manual seen_ids merge with deduplicate()

Depends on #45 (extract orchestration)
Closes #40

Test plan

  • All 535 unit tests pass (4 new parameterized tests)
  • ruff check and ruff format clean

@jakebromberg jakebromberg force-pushed the refactor/extract-orchestration branch 4 times, most recently from 7170c35 to c51684d Compare February 22, 2026 16:43
@jakebromberg jakebromberg changed the base branch from refactor/extract-orchestration to main February 22, 2026 16:51
Jake Bromberg added 2 commits February 22, 2026 08:57
Add allow_compilations parameter to matches_artist_or_compilation() so
callers can opt out of accepting compilation artists. Use the utility in
filter_results_by_artist (with allow_compilations=False) and
_discogs_cross_reference (conditionally based on Discogs release type),
replacing inline startswith/is_compilation_artist logic. Replace manual
seen_ids merge in search_compilations_for_track with deduplicate().
@jakebromberg jakebromberg force-pushed the refactor/consolidate-artist-filtering branch from 835c4e0 to 9455aa6 Compare February 22, 2026 18:18
@jakebromberg jakebromberg merged commit 228bfb0 into main Feb 22, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

refactor: consolidate artist filtering with allow_compilations parameter

1 participant