Last active
August 29, 2015 14:25
-
-
Save andkon/5d9b019a3eb8918c99ac to your computer and use it in GitHub Desktop.
davesingskaraoke
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import pyen | |
en = pyen.Pyen(YOUR_API_KEY) | |
songs = [] | |
for row in db: | |
try: | |
res = en.get('song/search', title=row.title, artist=row.artist, bucket=["song_type"]) | |
if len(res.get('songs')) > 0: | |
songs.append(res.get('songs')[0]) | |
except pyen.PyenException: | |
# fuck dat shit | |
pass |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment