I still get invalid URL for youtu.be links #104

Closed
opened 2026-02-20 21:02:34 -05:00 by deekerman · 5 comments
Owner

Originally created by @fridakiriakos on GitHub (Aug 7, 2011).

Hello Everyone

I have downloaded the latest version of youtube-dl and I still get the same error for youtu.be links.

Here is the output I always get when downloading those links:
[frida@localhost youtube]$ python youtube-dl http://youtu.be/Rs6RefV1td4
WARNING: Falling back on generic information extractor.
[generic] Rs6RefV1td4: Downloading webpage
[generic] Rs6RefV1td4: Extracting information
ERROR: Invalid URL: http://youtu.be/Rs6RefV1td4

Thanks a lot.
Frida

Originally created by @fridakiriakos on GitHub (Aug 7, 2011). Hello Everyone I have downloaded the latest version of youtube-dl and I still get the same error for youtu.be links. Here is the output I always get when downloading those links: [frida@localhost youtube]$ python youtube-dl http://youtu.be/Rs6RefV1td4 WARNING: Falling back on generic information extractor. [generic] Rs6RefV1td4: Downloading webpage [generic] Rs6RefV1td4: Extracting information ERROR: Invalid URL: http://youtu.be/Rs6RefV1td4 Thanks a lot. Frida
Author
Owner

@phihag commented on GitHub (Aug 7, 2011):

youtu.be links are just 302s to the actual URL, i.e. they never worked. You'll notice that when you give youtube-dl the real URL as determined with

curl -Is http://youtu.be/Rs6RefV1td4 | sed -n 's#Location: ##p'

, you can plug the resulting URL into youtube-dl and it works. We should handle all 302 redirects in the generic IE.

@phihag commented on GitHub (Aug 7, 2011): youtu.be links are just `302`s to the actual URL, i.e. they never worked. You'll notice that when you give youtube-dl the real URL as determined with ``` curl -Is http://youtu.be/Rs6RefV1td4 | sed -n 's#Location: ##p' ``` , you can plug the resulting URL into youtube-dl and it works. We should handle all 302 redirects in the generic IE.
Author
Owner

@fridakiriakos commented on GitHub (Aug 7, 2011):

I have tried plugging the resulting URL into youtube-dl it did not work:

[frida@localhost youtube]$ curl -Is http://youtu.be/Rs6RefV1td4 | sed -n 's#Location: ##p'
http://www.youtube.com/watch?v=Rs6RefV1td4&feature=youtu.be

[frida@localhost youtube]$ python youtube-dl http://www.youtube.com/watch?v=Rs6RefV1td4&feature=youtu.be
[1] 21192
[frida@localhost youtube]$ [youtube] Setting language
[youtube] www.youtube.com/: Downloading video webpage
ERROR: unable to download video webpage: HTTP Error 404: Not Found

However we used to download youtu.be links all the time, this is the first time this happens, How did it work before? the generic IE also results in the invalid URL, Could you please advise me on how to solve this issue?
I would really appreciate it.

Thank you
Frida

@fridakiriakos commented on GitHub (Aug 7, 2011): I have tried plugging the resulting URL into youtube-dl it did not work: [frida@localhost youtube]$ curl -Is http://youtu.be/Rs6RefV1td4 | sed -n 's#Location: ##p' http://www.youtube.com/watch?v=Rs6RefV1td4&feature=youtu.be [frida@localhost youtube]$ python youtube-dl http://www.youtube.com/watch?v=Rs6RefV1td4&feature=youtu.be [1] 21192 [frida@localhost youtube]$ [youtube] Setting language [youtube] www.youtube.com/: Downloading video webpage ERROR: unable to download video webpage: HTTP Error 404: Not Found However we used to download youtu.be links all the time, this is the first time this happens, How did it work before? the generic IE also results in the invalid URL, Could you please advise me on how to solve this issue? I would really appreciate it. Thank you Frida
Author
Owner

@fridakiriakos commented on GitHub (Aug 7, 2011):

I am sorry, I have tried to do the above again and it worked, sorry for the inconvenience.

But I am still wondering how it worked before the Aug 4th.

Thanks a lot.

@fridakiriakos commented on GitHub (Aug 7, 2011): I am sorry, I have tried to do the above again and it worked, sorry for the inconvenience. But I am still wondering how it worked before the Aug 4th. Thanks a lot.
Author
Owner

@phihag commented on GitHub (Aug 7, 2011):

@fridakiriakos youtu.be links worked before because we did not treat them as generic redirects, but extracted the youtube ID. The above patch should fix it; alternatively, you can also use my fork of youtube-dl.

@phihag commented on GitHub (Aug 7, 2011): @fridakiriakos youtu.be links worked before because we did _not_ treat them as generic redirects, but extracted the youtube ID. The above patch should fix it; alternatively, you can also use [my fork](https://raw.github.com/phihag/youtube-dl/master/youtube-dl) of youtube-dl.
Author
Owner

@fridakiriakos commented on GitHub (Aug 7, 2011):

thank you so much, both version work well :)

appreciate all your help.

@fridakiriakos commented on GitHub (Aug 7, 2011): thank you so much, both version work well :) appreciate all your help.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/youtube-dl#104
No description provided.