Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
Backups
youtube-dl
Commits
2297c0d7
Unverified
Commit
2297c0d7
authored
Oct 19, 2019
by
Sergey M․
Browse files
[facebook] Bypass download rate limits (closes #21018)
parent
824fa511
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
0 deletions
+5
-0
youtube_dl/extractor/facebook.py
youtube_dl/extractor/facebook.py
+5
-0
No files found.
youtube_dl/extractor/facebook.py
View file @
2297c0d7
...
...
@@ -405,6 +405,11 @@ class FacebookIE(InfoExtractor):
if
not
formats
:
raise
ExtractorError
(
'Cannot find video formats'
)
# Downloads with browser's User-Agent are rate limited. Working around
# with non-browser User-Agent.
for
f
in
formats
:
f
.
setdefault
(
'http_headers'
,
{})[
'User-Agent'
]
=
'facebookexternalhit/1.1'
self
.
_sort_formats
(
formats
)
video_title
=
self
.
_html_search_regex
(
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment