feat: handle ErrArtistNotFound in ScanArtist gracefully by using empty TypeFilter

This commit is contained in:
2026-07-26 11:36:32 +03:00
parent 4b4e852fd1
commit 395a7f9b07
2 changed files with 43 additions and 3 deletions

View File

@@ -76,9 +76,9 @@ Problem: Three separate filter implementations (`musicbrainz.FilterReleaseGroups
- [x] Run tests - must pass before task 7
### Task 7: Handle ErrArtistNotFound in ScanArtist gracefully
- [ ] In `ScanArtist`, wrap `GetArtistSettings` call; if `ErrArtistNotFound`, use empty `TypeFilter` (no filtering) instead of returning error
- [ ] Write test: create external_releases row for non-existent artist_id, verify ScanArtist succeeds and returns missing releases (with default no-filter behavior)
- [ ] Run tests - must pass before task 8
- [x] In `ScanArtist`, wrap `GetArtistSettings` call; if `ErrArtistNotFound`, use empty `TypeFilter` (no filtering) instead of returning error
- [x] Write test: create external_releases row for non-existent artist_id, verify ScanArtist succeeds and returns missing releases (with default no-filter behavior)
- [x] Run tests - must pass before task 8
### Task 8: Fix NotifyOnce map key to use composite ArtistID+RGID
- [ ] Change `missingByRGID` map key from `m.RGID` to `m.ArtistID + "|" + m.RGID` (or use a struct key)