-
-
Notifications
You must be signed in to change notification settings - Fork 7.5k
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
[core] Rework HTTP networking #2861
Closed
Closed
+4,051
−1,864
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
coletdjnz
added
enhancement
New feature or request
help-wanted
Extra attention is needed
needs-testing
Patch needs testing
labels
Feb 23, 2022
12 tasks
Closed
9 tasks
This was referenced Apr 22, 2022
Closed
9 tasks
9 tasks
9 tasks
coletdjnz
commented
May 14, 2022
pukkandan
force-pushed
the
master
branch
2 times, most recently
from
May 18, 2022 03:35
a63ff77
to
b14d523
Compare
7 tasks
coletdjnz
removed
help-wanted
Extra attention is needed
needs-testing
Patch needs testing
labels
Jun 8, 2022
coletdjnz
force-pushed
the
network-overhaul
branch
from
June 11, 2022 08:25
c3dd16b
to
f221720
Compare
coletdjnz
commented
Jun 11, 2022
This was referenced Jun 22, 2022
pukkandan
reviewed
Jun 23, 2022
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
My thoughts after skimming through
pukkandan
reviewed
Jun 24, 2022
9 tasks
pukkandan
reviewed
Jun 24, 2022
pukkandan
reviewed
Jun 24, 2022
pukkandan
force-pushed
the
network-overhaul
branch
2 times, most recently
from
June 24, 2022 20:30
15115a9
to
c21bc7d
Compare
pukkandan
force-pushed
the
network-overhaul
branch
from
July 15, 2023 06:06
1ebb0a6
to
6d7d8af
Compare
pukkandan
force-pushed
the
network-overhaul
branch
from
July 15, 2023 06:16
a015b66
to
8e3bc89
Compare
pukkandan
force-pushed
the
network-overhaul
branch
from
July 15, 2023 09:57
1165025
to
393627c
Compare
pukkandan
force-pushed
the
network-overhaul
branch
from
July 15, 2023 10:03
393627c
to
591f915
Compare
pukkandan
added a commit
to pukkandan/yt-dlp-dev
that referenced
this pull request
Jul 15, 2023
No actual changes - code is only moved around
pukkandan
pushed a commit
to pukkandan/yt-dlp-dev
that referenced
this pull request
Jul 15, 2023
New networking interface consists of a `RequestDirector` that directs each `Request` to appropriate `RequestHandler` and returns the `Response` or raises `RequestError`. The handlers define adapters to transform its internal Request/Response/Errors to our interfaces. User-facing changes: - Fix issues with per request proxies on redirects for urllib - Support for `ALL_PROXY` environment variable for proxy setting - Support for `socks5h` proxy - Closes yt-dlp#6325, ytdl-org/youtube-dl#22618, ytdl-org/youtube-dl#28093 - Raise error when using `https` proxy instead of silently converting it to `http` Authored by: coletdjnz
pukkandan
pushed a commit
to pukkandan/yt-dlp-dev
that referenced
this pull request
Jul 15, 2023
Authored by: coletdjnz, pukkandan
aalsuwaidi
pushed a commit
to aalsuwaidi/yt-dlp
that referenced
this pull request
Apr 21, 2024
No actual changes - code is only moved around
aalsuwaidi
pushed a commit
to aalsuwaidi/yt-dlp
that referenced
this pull request
Apr 21, 2024
New networking interface consists of a `RequestDirector` that directs each `Request` to appropriate `RequestHandler` and returns the `Response` or raises `RequestError`. The handlers define adapters to transform its internal Request/Response/Errors to our interfaces. User-facing changes: - Fix issues with per request proxies on redirects for urllib - Support for `ALL_PROXY` environment variable for proxy setting - Support for `socks5h` proxy - Closes yt-dlp#6325, ytdl-org/youtube-dl#22618, ytdl-org/youtube-dl#28093 - Raise error when using `https` proxy instead of silently converting it to `http` Authored by: coletdjnz
aalsuwaidi
pushed a commit
to aalsuwaidi/yt-dlp
that referenced
this pull request
Apr 21, 2024
Authored by: coletdjnz, pukkandan
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Merge before #3668
Please follow the guide below
x
into all the boxes [ ] relevant to your pull request (like that [x])Before submitting a pull request make sure you have:
In order to be accepted and merged into yt-dlp each piece of code must be in public domain or released under Unlicense. Check one of the following options:
What is the purpose of your pull request?
Description of your pull request and other information
This overhaul changes the underlying network request handling in yt-dlp.
The main goal of this was to abstract away all the network code to no longer directly interact with urllib for HTTP requests. This was so we could easily add support for more modern, updated HTTP libraries such as urllib3 to bring persistent connections, while also keeping our no-hard-dependency requirement.
TODO: https://github.com/coletdjnz/yt-dlp-dev/projects/2
Changes
The new HTTP networking interface:
RequestHandlers
Other Improvements:
ALL_PROXY
env proxy setting (andall://
proxy setting to cover all protocols)socks5h
(withsocks5
being treated assocks5h
in the ydl layer)Known issues / regressions
ALL_PROXY
set for any other program, yt-dlp will now pick it up.Future
ydl.proxies
,clean_proxies
andclean_headers
requests
#3668)--
This branch has been force updated. Old commit history can be found in this branch: https://github.com/coletdjnz/yt-dlp-dev/tree/network-overhaul-v2