-
Notifications
You must be signed in to change notification settings - Fork 10.1k
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
KeyError('@id',) youtube-dl [nrk] #25594
Comments
Your subject line should mention that the extractor is "[nrk]" (and you didn't follow the rules from the issue template). I have encountered this problem since yesterday on some of NRK's video's, most notably [NRKTVEpisodeIE], including its provided tests. It seems to be that "@id" is no longer provided in the embedded JSON. I was able to extract the first provided _TEST video ("Hellum's Kro") as well as another such video by modifying the video_id extraction:
Disclaimer: I cannot tell whether this breaks other videos, or whether both methods need to be provided, with one as fallback. It's just a proof of concept and "works for me"(TM) right now. |
Thank you for the answer! The error KeyError('@id',) appeared when I writed: "C:\Users\Admin\Desktop\yt-dl>youtube-dl --write-sub --sub-format ttml https://tv.nrk.no/serie/fra-boelle-til-bestevenn/sesong/1/episode/1/avspiller" in the Command prompt. Must I use another way? Can you paste the accurate text you used for Hellum's Kro? And what software to use? Where to put the command? Thank you in advance! |
I put the text you wrote in hellumskro.py, in Command prompt, and it says: C:\Users\Admin\Desktop>python hellumskro.py |
Actually, no. You must fix youtube-dl or wait for it to be fixed.
The fix I posted is a so-called diff. It's a textual instruction (which can be applied by developers, as they know how to) of what to change in youtube-dl's source code in order for this issue to go away. Since I'm running on Unix (Linux more precisely), it's easy to fix and run. I extracted the source code (or clone it from git), went into the source folder, applied the above fix, and then ran |
Implemented the quickfix for the '@id' error, now I'm getting 404 not found in stead: PS E:\git\youtube-dl> python.exe -m youtube_dl --write-sub https://tv.nrk.no/serie/foer-vi-doer/sesong/2/episode/1/avspiller |
I can reproduce this. This seems to be a different, additional issue. It happens on some series, not all. And of those failing have the |
Get content of meta tag Inspired by, and closes #25594
Can't see why the original method don't work for some streams. Bonus: provides 1080p quality Closes #24221
C:\Users\Admin\Desktop\yt-dl>youtube-dl --write-sub --sub-format ttml https://tv.nrk.no/serie/fra-boelle-til-bestevenn/sesong/1/episode/1/avspiller [NRKTVEpisode] fra-boelle-til-bestevenn/sesong/1/episode/1: Downloading webpage ERROR: An extractor error has occurred. (caused by KeyError('@id',)); please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; type youtube-dl -U to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.
Windows 7 64 bit. Youtube-dl is up-to-date 2020.06.06. I can download some videos from the same website.
Please help me!
The text was updated successfully, but these errors were encountered: