spotube icon indicating copy to clipboard operation
spotube copied to clipboard

Added method to fetch lyrics from AZLyrics or Genius as a fallback

Open Spectre-hidN opened this issue 1 year ago • 2 comments

Spotify's official lyrics for many songs are not available for non-premium users. So, both synced and unsynced lyrics tabs will throw an error. But, now, it will fetch the unsynced lyrics of the currently playing track from Azlyrics as a fallback. It uses the raw lyrics from the website, with no formatting or cleanups. So, for that reason, some non-UTF characters will break when it is rendered on the lyrics tab.

Spectre-hidN avatar Feb 21 '24 20:02 Spectre-hidN

Also, results are not that great. Hardly shows up for tracks except US/UK/ES one's I think genius.com has a wider collection of lyrics, so implementing it instead of AZLyrics should provide much better results

KRTirtho avatar Feb 24 '24 14:02 KRTirtho

Also, results are not that great. Hardly shows up for tracks except US/UK/ES one's I think genius.com has a wider collection of lyrics, so implementing it instead of AZLyrics should provide much better results

Genius requires an access token to use its official API. Also, the results are not always correct when using its API to search for a song (for example, FE!N by Travis Scott), and it might hit Error 429 if a user requests too many times. So, scraping the lyrics from a website is a better way to fetch the lyrics. I'll try my luck scraping the website if that doesn't violate their TOS.

Spectre-hidN avatar Feb 24 '24 17:02 Spectre-hidN