-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix(providers): warn if GTIN lookup found multiple results for Spotify / Tidal #29
Conversation
Some thoughts about this in general: In the long term it would be good if there could be some handling of multiple results. Something like this is already mentioned in the roadmap (#6) "Allow providers to return multiple releases, i.e. different variants (e.g. for Bandcamp)". While testing I had one release that failed the lookup for iTunes due to mismatched track length. However, iTunes found multiple results and one that would have matched the tracklists from other providers was among them. I unfortunately could not find the example again in my notes, but if I do I'll post it. For the barcode collision example 635669065024 it would also help as currently all of iTunes, Tidal and Spotify return one random result of the following two albums: https://music.apple.com/gb/album/barcheinu/1526351623 No matter which one you originally wanted to lookup you most likely end up with a mixed result on Harmony. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, that was fast!
…y / Tidal Adapt the existing logic already implemented in iTunes and generalize it.
I have found the following example in my notes, taken from the server logs: |
Just to clarify, the Beatport provider explicitly returns the first release from the search results with a matching barcode: harmony/providers/Beatport/mod.ts Line 106 in 0c9cd5f
I don't believe I've ever encountered a situation where a GTIN search has returned multiple releases, but the code will either return a single release or |
For Spotify and Tidal show a warning with a list of URLs if a GTIN lookup found more than one match.
Adapt the existing logic already implemented in iTunes and generalize it by adding a
ReleaseLookup.warnMultipleResults
helper.Notes:
This should resolve #25