-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Download error: KeyError: 'playNavigationEndpoint' #1038
Comments
Issue-Label Bot is automatically applying the label Links: app homepage, dashboard and code for this bot. |
A little more information, maybe it will be useful. Tried redirecting traffic through Tor to bypass YouTube blocking, it didn't work. I get similar errors on three different servers, on different subnets. I'm using Ubuntu 18.04 and CentOS 7 |
2nd error (from master branch install) Appears to be duplicate of #1025 further down. Try the following:
|
Now I get both errors at once, a complete list of what I did:
|
I'm getting this error as well. @Silverarmor's solution did not help, sadly.
|
While Debugging, here's what I found:
The Fix:
try:
linkBlock = contents['musicResponsiveListItemRenderer'] \
['overlay'] \
['musicItemThumbnailOverlayRenderer'] \
['content'] \
['musicPlayButtonRenderer'] \
['playNavigationEndpoint']
except KeyError:
continue
Please close this issue, if this fixes it. |
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: _linkBlock = contents['musicResponsiveListItemRenderer'] \
['overlay'] \
['musicItemThumbnailOverlayRenderer'] \
['content'] \
['musicPlayButtonRenderer']
try:
linkBlock = _linkBlock ['playNavigationEndpoint']
except KeyError:
continue |
Yup, You're right. Will make the suggested changes. |
Here is what I got when I add that block:
|
For me all youtubelink are None |
Corrected the code as suggested above. When downloading any individual songs, I get:
I launch a small playlist:
I launch the playlist from my first message:
Strangely enough, I made another virtual environment, fixed only the code and launched the playlist in it that I managed to download for the first time, now the process is also frozen. |
That's a different issue altogether. |
This seems to be an issue with requests. Retry downloading a few times. |
Here is what I get which is same with itmax78's one:
|
|
I have the same issue as lvlzyro. And yes, Youtube Music is available in my country as well. |
A fix for this is in the pipeline. Please wait a few days and install from master. |
This issue hasn't been fixed yet. I'm getting:
YouTube Music is available along YouTube. EDIT: This made it work again. |
Author: @s1as3r * Fix Issue #1038 Fixes [Issue #1038](#1038) - When searching for a song, spotdl gathers all the results that the youtube music api provides. - If one of the songs in the results is not available in a country, 'playNavigationEndpoint' key would not be present in it's result, hence this error. * Update provider.py Made Changes as suggested by @tytydraco * Update provider.py - Used `.get()` method instead of a try-except block.
In the evening I started downloading two playlists, they downloaded normally. In the morning I start downloading the next playlist and get an error:
I installed spotdl like this:
other installation options did not solve the problem. When installing from master branch, I get another error:
TypeError: cannot unpack non-iterable NoneType object
The text was updated successfully, but these errors were encountered: