Closed FiftyFour7250 closed 1 year ago
Correction. If no ArtistName in brackets, just words - it's works fine.
Examples: https://open.spotify.com/track/5ZOLcd8JCxHjrCQDp394IV?si=-mxkkE78Q8ikaE-N5okOMQ https://open.spotify.com/track/2K9aNlFNoh2UVY7K7iPMnS?si=LcV7PliERie2Qk1xW3n1-w https://open.spotify.com/track/20E9gUmSgH8SBCMevHItbk?si=MuLDYFkwSd-Y4bd2oDp0gQ https://open.spotify.com/track/4f80SteKqaB6M2JytEUrwT?si=45XbqivBRYepnlW70f-zPg https://open.spotify.com/track/6d3I7THB2bONUkxOo1DvmZ?si=XLZkQZ34QqSF1g7kLpVjPA
So problem is only in cases like (with...) and (feat. ....)
Cheers for the example, I have written up a regular expression to try and filter these out:
"title".replace(/\((feat\.|ft\.|with).+\)/, "").trim()
The results:
Input | Output | Expected? |
---|---|---|
Girl (feat. KAYTRANADA) | Girl | ✔️ |
All Eyez On Me (ft. Big Syke) | All Eyez On Me | ✔️ |
lovely (with Khalid) | lovely | ✔️ |
Walk On Water (feat. Beyoncé) | Walk On Water | ✔️ |
Tragic Endings (feat. Skylar Grey) | Tragic Endings | ✔️ |
Pursuit Of Happiness (Nightmare) | Pursuit Of Happiness (Nightmare) | ✔️ |
The Wolves (Act I and II) | The Wolves (Act I and II) | ✔️ |
Aghori (Dunkler Tag) | Aghori (Dunkler Tag) | ✔️ |
I'll put this in soon.
Let me know if this has worked - should be available in about 5mins
Seems like it fixed a lot, but not all. I checked different songs with "(feat. XXX )", and everything is fine, but with "(with XXX)" - something shows correctly, something does not. Few examples:
https://open.spotify.com/track/0u2P5u6lvoDfwTYjAADbn4?si=e0122c047fa241a3 - Song from my first message. It used to show a playlist, but now it shows an Arabic translation.
https://open.spotify.com/track/4g32MdRoqwGKQd3NXIRhpU?si=JiAKStdISY6EuPG0xoXmWQ - It's fine. https://open.spotify.com/track/09FfQO3PqHO4HIJL511Ksi?si=XN6XaW4NSBiQm5eTsCf_DA - Song from the same album, with the same artist, even the song name differs only in one word, but already Turkish translation
https://open.spotify.com/track/5CFJRZRq6sdKKtRwNPWbYv?si=c981f36d5bf94886 - Playlist
https://open.spotify.com/track/5AebNkVaY2zcdNFCqPBIV7?si=c31cb050d482455b - Playlist
https://open.spotify.com/track/7uPZooWh5ttHRokNHnAJyD?si=lr4rRoK7S_u1JqeXEWquWw - It's fine
https://open.spotify.com/track/38iBrrbbXyWaSPkmuDNgjZ?si=TLRqSSePQoODiIKVdCVlKw - Russian translate
¯\(ツ)/¯
I GET IT!
Songs whose lyrics are displayed incorrectly have a different artist on genius. Look.
Correct lyrics:
Wrong lyrics:
https://genius.com/artists/Eminem-and-jessie-reyez
Correct lyrics:
Wrong Lyrics:
https://genius.com/artists/Logic-and-dwn2earth
Get it?
Pretty much for each song that has more than one artist, I just search with the first artist's name. For example the song "Nice Guy (with Jessie Reyez)" you listed above, it searches for "Eminem Nice Guy".
There is no way to exactly match the lyrics, I am just searching for them based on the songs title and main artist. If you can recommend a better way to search, then I can check it out. At the moment, I'm doing this:
Hm... Try this:
I checked through genius search and it worked for every songs. This gave the first correct result, both for songs with a combined artists page, and for different ones. The only one songs this didn't work is Nice Guy, where the first Turkish translation is issued.
https://open.spotify.com/track/0u2P5u6lvoDfwTYjAADbn4?si=FcVNQMFhTv2JlDx964ijDg (Combined page) Search: "Billie Eilish & Khalid lovely"
https://open.spotify.com/track/5e7ldn9Kwo8Aw9Z8ql9cDj?si=rkh7EhX2Sr6n2vQpweNhoQ (Different pages) Search: "2Pac & Big Syke All Eyez On Me"
https://open.spotify.com/track/5CFJRZRq6sdKKtRwNPWbYv?si=_ngJq6jjRlSHeJlv5noB_g (Combined page) Search: "Kid Cudi & Skepta & Pop Smoke Show Out"
https://open.spotify.com/track/5CpsIb7SMFHjmAG8RvIWfq?si=YhBp7-u7SnyQ5Ue8qr_wBw (Different pages) Search: "Eminem & Skylar Grey Leaving Heaven"
Also, as an option, maybe you should block playlists, and translations? Or for songs with multiple artists, you should add a selection of lyrics with different options...
I like your idea and see your examples, however, I have a few examples that break from this change:
Closer to Comfort Dreamhouse
=> https://genius.com/Dreamhouse-closer-to-comfort-lyrics
b. Closer to Comfort Dreamhouse & Andy Cizek & Makari
=> No matches
c. Dreamhouse & Andy Cizek & Makari Closer to Comfort
=> No matches
d. Issue: No longer has a matchScars That I'm Hiding From Ashes to New
=> https://genius.com/From-ashes-to-new-scars-that-im-hiding-lyrics
b. Scars That I'm Hiding From Ashes to New & In Flames
=> https://genius.com/Gerald-haywood-2018-haywoodindahood-listening-log-annotated
c. From Ashes to New & In Flames Scars That I'm Hiding
=> https://genius.com/Gerald-haywood-2018-haywoodindahood-listening-log-annotated
d. Issue: Bad matchMadness Silverstein
=> https://genius.com/Silverstein-madness-lyrics
b. Madness Silverstein & Princess Nokia
=> https://genius.com/Genius-march-2020-singles-release-calendar-annotated
c. Silverstein & Princess Nokia Madness
=> https://genius.com/Genius-march-2020-singles-release-calendar-annotated
d. Issue: Bad matchMonsters All Time Low
=> https://genius.com/All-time-low-monsters-lyrics
b. Monsters All Time Low & blackbear
=> https://genius.com/Isabelle-hammonds-my-favorite-songs-annotated
c. All Time Low & blackbear Monsters
=> https://genius.com/Spotify-new-music-friday-4-3-20-annotated
d. Issue: Bad matchI use https://api.genius.com/search?q= to search for songs. Conveniently (/s), the GENIUS API does not always return the same results as the search on their site.
Is it possible to give the user a choice of each of the options? If the result in each of them of course is different. And by default, output one, I don't know, may be one that is more popular, or the option that has most successful results?
What about using the primary_artist
key as double check?
e.g. in pseudocode
query "{artist} {title}"
If (hits.any(hit => hit.primary_artist.name === artist)
return hit
query "{artist} & {title}
If (hits.any(hit => hit.primary_artist.name === artist)
return hit
query "any other format"
...
I am not too sure about the results, but it could be a better fallback solution?
Hopefully a85ec2e5fe32ee4a5bcf44b6494019f6d4015519 does something for this issue.
Pretty much the flow now is:
${artists[0]} ${title}
${artists.join(" & ")} ${title}
Closing due to inactivity
Hey. Thank you for dark theme, and pinned player. I found a bug where the lyrics for many songs are not displayed.
Seems like for all songs with brackets in the title, and most often it is "(feat. |ArtistName|)" and "(with |ArtistName|)" - incorrect lyrics are shown. Usually there are not even songs, but a Spotify playlist [For example this is for Eminem - Leaving Heaven (feat. Skylar Grey) ] It's funny, but it happens that the track is correct, but it shows the translation into a random language, not original. [For example this is for Kid Cudi - The Adventures of Moon Man & Slim Shady (with Eminem) ]
A few more examples (although you can easily find them by yourself): https://open.spotify.com/track/3PFaFVWq5wucLu6s4baj9D?si=utxymX1TRbCbWAio694ETQ --- Playlist https://open.spotify.com/track/0u2P5u6lvoDfwTYjAADbn4?si=v2yTpmGXQAqMIPw8Smb2HQ --- Playlist https://open.spotify.com/track/5e7ldn9Kwo8Aw9Z8ql9cDj?si=u1vIYoYJSoKBr8k-gEIuVA --- Translation https://open.spotify.com/track/7CcoUAtUcYhUfBsmtn0ajO?si=1eFjAHx1RZqm-sdmBAeguQ --- Translation
I've checked about 20 songs with brackets, and for none correct lyrics all of them. I hope you can fix it)