spotify-downloader: Download error: KeyError: 'playNavigationEndpoint'
In the evening I started downloading two playlists, they downloaded normally. In the morning I start downloading the next playlist and get an error:
Fetching Playlist...
Traceback (most recent call last):
File "/root/envspotdl/bin/spotdl", line 8, in <module>
sys.exit(console_entry_point())
File "/root/envspotdl/lib/python3.8/site-packages/spotdl/__main__.py", line 114, in console_entry_point
songObjList = get_playlist_tracks(request)
File "/root/envspotdl/lib/python3.8/site-packages/spotdl/search/utils.py", line 82, in get_playlist_tracks
song = SongObj.from_url(
File "/root/envspotdl/lib/python3.8/site-packages/spotdl/search/songObj.py", line 66, in from_url
youtubeLink = SongObj.searchProvider(
File "/root/envspotdl/lib/python3.8/site-packages/spotdl/search/provider.py", line 478, in search_and_get_best_match
results = search_and_order_ytm_results(
File "/root/envspotdl/lib/python3.8/site-packages/spotdl/search/provider.py", line 366, in search_and_order_ytm_results
results = __query_and_simplify(songSearchStr)
File "/root/envspotdl/lib/python3.8/site-packages/spotdl/search/provider.py", line 176, in __query_and_simplify
linkBlock = contents['musicResponsiveListItemRenderer'] \
KeyError: 'playNavigationEndpoint'
I installed spotdl like this:
pip3 install spotdl
pip3 uninstall -y pytube3
pip3 install git+https://github.com/nficano/pytube
other installation options did not solve the problem. When installing from master branch, I get another error:
TypeError: cannot unpack non-iterable NoneType object
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Comments: 19 (6 by maintainers)
Yup, You’re right. Will make the suggested changes.
It could be a good idea to put an error message there too; not sure how the rest of the program handles errors. Also, it could be a bad idea to wrap that whole thing. If there’s an error in the future regarding any of those keys, we would never be able to know. Maybe we can do something like this:
Now I get both errors at once, a complete list of what I did:
Here is what I got when I add that block: