for most audio and video something that will work a lot of the time (besides just yt-dlp which does support hundreds of common sites but not all), is using either browser tools (network tab) or an extension (there are many) to catch any URLs with the file extension .m3u8, and then downloading that m3u8 URL with yt-dlp or other downloader tool that can assemble it into a single audio or video file.
(Also: comrades with programming experience, contributing to yt-dlp is very fun, easy, and rewarding, you should try it next time you want to download from a site that isn’t supported)
I’ve been getting 403 when I try to use it recently, and when I try to update it, apt insists I already have the latest version. Maybe Google has blocked every outlet of my VPN?
This is new to me. Seems I have to set up a simulated browser using a command or program called curl? What do I need to understand to not screw this up?
Using a vpn is usually not going to work with anything that hits youtube. Google are really fast at putting captchas on anonymised traffic which breaks most 3rd party access
Bots will use VPN nodes as cheap proxies. They will abuse it until google bans the IP for abuse. The bots rotate to a new node and continue. Real users are also banned from that node as well until google forgives it.
Google eventually get savvy to it. Your options are try again without a vpn, try with the session cookies from a logged in session, or wait until yt-dl patch whatever fresh hell google are doing to block you
if the problem is your vpn then it won’t help. the tooling is probably already included in your yt-dlp. just put --impersonate chrome on the end of your call in the terminal
yt_dlp.utils.YoutubeDLError: Impersonate target “chrome” is not available. Use --list-impersonate-targets to see available targets. You may be missing dependencies required to support this target.
I use yt-dlp a lot, and at least on windows I have my own custom script that I use that just runs the raw exe with parameters that I set. Anytime it breaks I download the new exe and it works fine again. I used it this week actually. Maybe this sort of option will work for you.
I’m on Linux Mint, and the installation manager called Apt has me on a version of yt-dlp from March. Maybe there are arguments that will force it to install more recent experimental builds or something? I just don’t know what to look for. I’m more of a Windows refugee than someone who wants to make Linux my hobby, you know?
For sure. Definitely the reason I haven’t switched to Linux yet. I’m sure there’s some way to force it to pick up the latest version, some Linux comrade will come in here at some point and tell us what that command is lol
I think that only applies if you’ve compiled it from source? System insists that since it is installed with apt, it must be updated with an apt command. But apt can’t seem to understand that there are stable versions later than March, and I don’t know how to teach it.
I’m not sure what the best solution will be for you. I think you can enable a 3rd-party repository that contains the most up-to-date version of yt-dlp.
It’s been discussed in the Mint forums, but they block my VPN from accessing the site :)
If you are curious, this is how I use yt-dlp. Effort-post incoming, beware, and bare with me. It might seem complicated but I tried my best to simplify.
You can use CTRL+O and CTRL+X to save and then quit.
chmod +x $HOME/.local/bin/yt-dlp (give yourself permission to eXecute the command)
Now any time you run yt-dlp from the terminal, it will search all of those directories inside $PATH until it finds yt-dlp. It will find your custom script, and correctly run the python venv’s version of yt-dlp with any of the arguments you supplied.
If you noticed and are curious, yt-dlp inside of $HOME/.local/bin/yt-dlp doesn’t cause an infinite loop of it calling itself over and over again. Why? Because when you do source$HOME/.local/yt-dlp-venv/bin/activate, it changes your $PATH!
Thank you, I found this way before I saw your reply, although I have to sudo to run this installation of yt-dlp, which seems not ideal from a security perspective:
Since you went to the effort and I do want to understand my system better, I will study your explanation closely even though my video downloading woes are solved.
I strongly prefer extensions/bookmarklets for this reason. it’s already in my memory, don’t clone the whole universe (or make an additional HTTP request) just to download it).
I’ve always been able to find the image using the inspector (f12) on firefox-derived browsers. Wish I could always say the same for mp3s and videos.
for most audio and video something that will work a lot of the time (besides just yt-dlp which does support hundreds of common sites but not all), is using either browser tools (network tab) or an extension (there are many) to catch any URLs with the file extension .m3u8, and then downloading that m3u8 URL with yt-dlp or other downloader tool that can assemble it into a single audio or video file.
(Also: comrades with programming experience, contributing to yt-dlp is very fun, easy, and rewarding, you should try it next time you want to download from a site that isn’t supported)
For people who want a GUI tool, VLC will download those m3u8 files and stitch the parts together.
Thank you.
Yt-dlp
I’ve been getting 403 when I try to use it recently, and when I try to update it, apt insists I already have the latest version. Maybe Google has blocked every outlet of my VPN?
Are you using the browser impersonation feature?
This is new to me. Seems I have to set up a simulated browser using a command or program called curl? What do I need to understand to not screw this up?
Using a vpn is usually not going to work with anything that hits youtube. Google are really fast at putting captchas on anonymised traffic which breaks most 3rd party access
I was downloading youtube videos just fine with a vpn until a couple weeks ago. I have no idea what changed.
Bots will use VPN nodes as cheap proxies. They will abuse it until google bans the IP for abuse. The bots rotate to a new node and continue. Real users are also banned from that node as well until google forgives it.
Google eventually get savvy to it. Your options are try again without a vpn, try with the session cookies from a logged in session, or wait until yt-dl patch whatever fresh hell google are doing to block you
that’s surprising given that tor and youtube has a like 50% success rate from what I remember
if the problem is your vpn then it won’t help. the tooling is probably already included in your yt-dlp. just put
--impersonate chromeon the end of your call in the terminalwell, try --list-impersonate-targets then, what’ve you got
It was on the list, but every item on the list was greyed out and labeled (unavailable)
I use yt-dlp a lot, and at least on windows I have my own custom script that I use that just runs the raw exe with parameters that I set. Anytime it breaks I download the new exe and it works fine again. I used it this week actually. Maybe this sort of option will work for you.
I’m on Linux Mint, and the installation manager called Apt has me on a version of yt-dlp from March. Maybe there are arguments that will force it to install more recent experimental builds or something? I just don’t know what to look for. I’m more of a Windows refugee than someone who wants to make Linux my hobby, you know?
For sure. Definitely the reason I haven’t switched to Linux yet. I’m sure there’s some way to force it to pick up the latest version, some Linux comrade will come in here at some point and tell us what that command is lol
I use the python module instead for this reason, but I think this is what you have to do to update yt-dlp when it’s installed from apt:
sudo yt-dlp -UI think that only applies if you’ve compiled it from source? System insists that since it is installed with apt, it must be updated with an apt command. But apt can’t seem to understand that there are stable versions later than March, and I don’t know how to teach it.
I’m not sure what the best solution will be for you. I think you can enable a 3rd-party repository that contains the most up-to-date version of yt-dlp.
It’s been discussed in the Mint forums, but they block my VPN from accessing the site :)
https://forums.linuxmint.com/viewtopic.php?t=450307
https://forums.linuxmint.com/viewtopic.php?t=440928
If you are curious, this is how I use
yt-dlp. Effort-post incoming, beware, and bare with me. It might seem complicated but I tried my best to simplify.When I run
echo $PATHon my system, I see this:username@somepc:~$ echo $PATH /var/home/username/.local/bin:/var/home/username/bin:/usr/local/bin:/usr/bin:/bin:/usr/local/sbinYour PATH might look more like
/home/username/.local/bin.* If it does not include a
/.local/bin, maybe send me your$PATHand I can recommend a substitution instead.What this means, is that any EXECUTABLE inside these directories will be executed if typed from the command line.
So in order, you do this (yes, literally,
$HOME, the terminal will convert that to your home directory):python3 -m venv "$HOME/.local/yt-dlp-venv"(create a virtual space forpython3outside ofapt)source $HOME/.local/yt-dlp-venv/bin/activate(toggle the virtual space forpython3for the duration of the current terminal window)python3 -m pip install yt-dlp(installyt-dlpmodule inside the virtual space)nano $HOME/.local/bin/yt-dlp, paste this inside:#!/usr/bin/env bash source $HOME/.local/yt-dlp-venv/bin/activate pip install --upgrade yt-dlp yt-dlp "$@"You can use
CTRL+OandCTRL+Xto save and then quit.chmod +x $HOME/.local/bin/yt-dlp(give yourself permission to eXecute the command)Now any time you run
yt-dlpfrom the terminal, it will search all of those directories inside$PATHuntil it findsyt-dlp. It will find your custom script, and correctly run the pythonvenv’s version ofyt-dlpwith any of the arguments you supplied.If you noticed and are curious,
yt-dlpinside of$HOME/.local/bin/yt-dlpdoesn’t cause an infinite loop of it calling itself over and over again. Why? Because when you dosource $HOME/.local/yt-dlp-venv/bin/activate, it changes your$PATH!(yt-dlp-venv) username@somepc:~$ echo $PATH /var/home/username/.local/yt-dlp-venv/bin:/var/home/username/.local/bin:/var/home/username/bin:/usr/local/bin:/usr/bin:/bin:/usr/local/sbinBecause the real
yt-dlpexists inside$HOME/.local/yt-dlp-venv/bin, it finds the executable first instead of the one inside$HOME/.local/binThank you, I found this way before I saw your reply, although I have to
sudoto run this installation of yt-dlp, which seems not ideal from a security perspective:Since you went to the effort and I do want to understand my system better, I will study your explanation closely even though my video downloading woes are solved.
I strongly prefer extensions/bookmarklets for this reason. it’s already in my memory, don’t clone the whole universe (or make an additional HTTP request) just to download it).
What extensions/bookmarklets are you referring to?