How a get more than 400 song from a playlist?
eribito opened this issue · 2 comments
eribito commented
browniebroke commented
Can you please avoid posting screenshot? It's not possible to copy/paste from an image. Making a code snippet is a lot more useful.
I can't remember if we have a proper pagination in the client or if it's a limitation of the Deezer API itself.
deezer-python/deezer/resources.py
Lines 269 to 270 in 2373bf6
You can try to do playlist.iter_relation('tracks')
maybe?
eribito commented
Sorry about the image. I tried how you said and it worked well. Thanks for you help.
import deezer
client = deezer.Client()
playlist = client.get_playlist(5308276702)
j = 0
for i in playlist.iter_relation('tracks'):
j+=1
print(j)