Closed juxuanu closed 1 year ago
Normally we get video_id
from initial URI. ID is a must as its used with the YT API everywhere. What this probably needs to do is a change plugin_query ()
implementation in youtube plugin to detect this special */live
case, continuing without the ID and then downloading webpage as HTML and extracting ID value from it, then proceeding like we do normally.
It doesn't seem trivial. Scraping the live link resulted in no video ID... I have been looking around the yt-dlp
code but I need more time to understand the code. I also took a look at the function you mentioned and it'd seem trivial once there is a way to figure out the video ID.
@juxuanu Should be supported by linked above PR. I will add a test case to it before merging.
As discussed in the Matrix channel, GTuber doesn't handle this kind of links: https://youtube.com/nasa/live.
Example Clapper output:
A workaround is to access the URL, right-click the video and "Copy video URL", which lets you obtain a URL that GTuber can handle. In the example above, that'd be https://youtu.be/nA9UZF-SZoQ.
yt-dlp can handle this correctly, so it might be worth checking out what they do.