-
-
Notifications
You must be signed in to change notification settings - Fork 5.9k
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
[TV5MONDE] Unable to download webpage: HTTP Error 403: Forbidden (caused by <HTTPError 403: Forbidden>) #10153
Comments
Looks like this may be caused by akamai TLS fingerprinting / anti-bot protection. Try installing curl_cffi and adding |
Works for me. Thx |
Can I compile yt-dlp from source with curl_cffi built in? If so, how? |
Yes, but you can't include curl_cffi in the unix zipfile build (which you were using in your original log), since it imports python dependencies from your environment. You can include it in a pyinstaller build, though. If you're on linux, you can run this from the project root directory: git restore yt_dlp/version.py
git checkout master && git pull # if you want to build from a different branch/tag/commit, skip this
make clean
python3 -m venv .venv
source .venv/bin/activate
python3 devscripts/install_deps.py -o -i build
python3 devscripts/install_deps.py -i pyinstaller -i secretstorage -i curl-cffi
python3 devscripts/update-version.py
python3 devscripts/make_lazy_extractors.py
python3 -m bundle.pyinstaller |
Le mar. 18 juin 2024 à 16:24, bashonly ***@***.***> a écrit :
You can include it in a pyinstaller build, though. If you're on linux, you can run this from the project root directory:
git checkout master && git pull # if you want to build from a different branch/tag/commit, skip this
make clean
python3 -m venv .venv
source .venv/bin/activate
python3 devscripts/install_deps.py -o -i build
python3 devscripts/install_deps.py -i pyinstaller -i secretstorage -i curl-cffi
python3 devscripts/update-version.py
python3 devscripts/make_lazy_extractors.py
python3 -m bundle.pyinstaller
Thanks. I followed this to the letter, but... where is the binary now?
In my directory I have:
~/git/yt-dlp$ ll
total 772
drwxr-xr-x 3 oc oc 4096 Jun 18 16:38 build/
drwxr-xr-x 4 oc oc 4096 Jun 18 16:38 bundle/
-rw-r--r-- 1 oc oc 446073 Jun 18 16:32 Changelog.md
-rw-r--r-- 1 oc oc 3271 Jun 18 16:32 Collaborators.md
-rw-r--r-- 1 oc oc 37391 Jun 18 16:32 CONTRIBUTING.md
-rw-r--r-- 1 oc oc 6364 Jun 18 16:32 CONTRIBUTORS
drwxr-xr-x 3 oc oc 4096 Jun 18 16:36 devscripts/
drwxr-xr-x 2 oc oc 4096 Jun 18 16:39 dist/
-rw-r--r-- 1 oc oc 1211 Jun 18 16:32 LICENSE
-rw-r--r-- 1 oc oc 7831 Jun 18 16:32 Makefile
-rw-r--r-- 1 oc oc 1676 Jun 18 16:32 public.key
-rw-r--r-- 1 oc oc 9724 Jun 18 16:32 pyproject.toml
-rw-r--r-- 1 oc oc 163630 Jun 18 16:32 README.md
-rw-r--r-- 1 oc oc 861 Jun 18 16:32 setup.cfg
-rw-r--r-- 1 oc oc 56657 Jun 18 16:32 supportedsites.md
drwxr-xr-x 3 oc oc 4096 Jun 18 16:32 test/
drwxr-xr-x 11 oc oc 4096 Jun 18 16:38 yt_dlp/
-rw-r--r-- 1 oc oc 47 Jun 18 16:32 yt-dlp.cmd
-rw-r--r-- 1 oc oc 749 Jun 18 16:38 yt-dlp_linux.spec
-rwxr-xr-x 1 oc oc 114 Jun 18 16:32 yt-dlp.sh*
I am not sure which directories were there before running all those commands.
|
relative path of the binary should be |
bashonly ***@***.***> a écrit :
relative path of the bianry should be dist/yt-dlp_linux
Thanks. Using:
/home/oc/git/yt-dlp/dist/yt-dlp_linux -o "%(title)s.%(ext)s" -S
res:900 https://www.tv5monde.com/tv/video/72857-le-journal-de-la-rtbf-edition-du-18-06-24-13h
I was finally able to download this video.
Now a few questions, if you don't mind:
1) Do I have to follow the above procedure (which I just copied and
pasted as I have no idea what it does) every time I want a new version
of yt-dlp?
2) Could the Linux binary theoretically be shipped with curl-cffi by default?
3) If so, can I raise a feature request?
|
If you want a binary with curl_cffi included in it, yes. As an alternative, you could install yt-dlp via pipx or with pip (in a virtual environment), which would make updating less painful.
Theoretically, yes. But practically, it's not possible right now. Our
Not necessary. We hope to include curl_cffi in the linux binaries at some point in the future, but either we'll need curl_cffi to publish a stable 0.7.0 release (for the musllinux wheels) or we'll need to revamp our whole Linux build flow. (It's likely we'll end up doing the latter anyways.) The one certainty is that it's going to take some time. |
@bashonly
Amen to that. Thanks for the assistance.
|
DO NOT REMOVE OR SKIP THE ISSUE TEMPLATE
Checklist
Region
United Kingdom
Provide a description that is worded well enough to be understood
Downloadind videos from TV5Moinde fail with " HTTP Error 403: Forbidden " . See verbose output. Adding "--cookies-from-browser firefox" doesn't help. I can play the video fine in the browser and it does not require login.
Provide verbose output that clearly demonstrates the problem
yt-dlp -vU <your command line>
)'verbose': True
toYoutubeDL
params instead[debug] Command-line config
) and insert it belowComplete Verbose Output
The text was updated successfully, but these errors were encountered: