1

Suddenly I seem to be having problems downloading videos from youtube using youtube-dl. I am running ubuntu 20.04.2

I did seem to upgrade youtube-dl using this suggestion:

pip3 install --upgrade youtube-dl

and when I check for the version using the command

youtube-dl --version

gives 2021.01.16

However when I try to make use of youtube-dl I get the message;

youtube-dl -f mp4 https://www.youtube.com/watch?v=5BXtgq0Nhsc
[youtube] 5BXtgq0Nhsc: Downloading webpage
ERROR: 5BXtgq0Nhsc: YouTube said: Unable to extract video data

I even tried removing youtube-dl and reinstall from the Software launcher with no luck.

(I had a similar problem running youtube-dl in windows but the problem was resolved there when I updated youtube-dl)

Pablo Bianchi
  • 17,371
jim
  • 121

3 Answers3

1

Update it to the latest version with

sudo youtube-dl --update

and then try again.

Edit: Since you wrote you installed it with a package manager and thus you can't update it so easily, for this particular software I'd recommend to install it from its upstream site https://youtube-dl.org/ to your /usr/local/bin directory and use it from there; then you can update it whenever needed (which is often because YouTube often changes some stuff to thwart software like youtube-dl).

You can either have a version from an official repo which is always slightly outdated, or a working one. As a general rule of thumb, you need to update it whenever you want to use it.

I just updated it, and it gives me

sh@balrog:~$ youtube-dl --version
2021.04.01
HuHa
  • 3,525
1

The problem seems to have been resolved by updating via pip3 command. It seems I needed a restart ... sorry, I'm a newbie and this is a newbie mistake: "have you tried turning it on and off". I'm happy to leave the question here for other newbie's, but otherwise don't mind if removed..

jim
  • 121
0

Here's what worked for me. I'm not a fan of the "snap store" but it successfully installed the latest version (2021.06.06) on my xubuntu 20.04.2 Cheers!

Denis
  • 1