Closed danielcliu closed 4 years ago
Hi @danielcliu, I like the idea of an include_features
tag, but does the Genius.com search interface provide this sort of functionality? I suppose we could just take all songs returned when searching for "Kendrick Lamar" even if the song's author != Kendrick, but the title contains "featuring" or "feat.", etc.
Do you want to put a proof of concept together?
The Genius.com search interface seems to provide this functionality off the bat, most easily seen if you go to an artist's page and then click on the "Show all songs by GET /artists/:id/songs
input with id = 1421
(Kendrick's ID) and sort = popularity
. Then in the second response Kendrick Lamar should not be the primary artist.
Added in #124
Desired Feature I think it would be nice to have an option to include an artist's featured work to be returned in the
get_artist_songs()
call. This would allow someone to really get the entirety of a specific artist's work. For example, right now if yougenius.search_artist('Kendrick Lamar', max_songs=5)
you will getbut it would be nice to have the option to get songs he features on as well, so that the top 5 would look like
Proposed Solution Include an optional boolean in the
search_artist()
call to allow for features to be allowed to be returned in the results. iegenius.search_artist('Kendrick Lamar', include_features=True)
Alternatives Considered I don't have any realistic ones outside of just saying that an artist object can't contain songs where they aren't the main artist, and mandating that features must be found by searching for the original artist or the song by name.
Additional context I am willing to work on this issue, if that is ok