johnwmillr / LyricsGenius

Download song lyrics and metadata from Genius.com 🎶🎤
http://www.johnwmillr.com/scraping-genius-lyrics/
MIT License
898 stars 159 forks source link

Save song data in different json files. #150

Closed chethan25 closed 4 years ago

chethan25 commented 4 years ago

Feature to save all of artist's songs to different json files instead of one file would greatly help my project.

allerter commented 4 years ago

Since the artist's songs are all already available using the artist.songs attribute, you could easily do this yourself:

# suppose we have an artist object
for song in artist.songs:
    song.save_lyrics()
chethan25 commented 4 years ago

This works but I was getting timeout error so I put the code in try block and sleep for 5 min if there's an exception. thanks for the help.