mirror of
https://github.com/internetarchive/brozzler.git
synced 2025-02-24 16:49:56 -05:00
Merge branch 'ytdlp_tmpdir' into qa
This commit is contained in:
commit
db56c8fb00
@ -444,7 +444,7 @@ class BrozzlerWorker:
|
||||
self.logger.trace("%r", chrome_msg)
|
||||
if chrome_msg.get("params", {}).get("versions"):
|
||||
url = chrome_msg.get("params", {}).get("versions")[0].get("scriptURL")
|
||||
if url and url.startswith('http') and url not in sw_fetched:
|
||||
if url and url.startswith("http") and url not in sw_fetched:
|
||||
self.logger.info("fetching service worker script %s", url)
|
||||
self._fetch_url(site, url=url)
|
||||
sw_fetched.add(url)
|
||||
|
@ -428,7 +428,7 @@ def do_youtube_dl(worker, site, page):
|
||||
Returns:
|
||||
`list` of `str`: outlink urls
|
||||
"""
|
||||
with tempfile.TemporaryDirectory(prefix="brzl-ydl-") as tempdir:
|
||||
with tempfile.TemporaryDirectory(prefix="brzl-ydl-", dir="/tmp") as tempdir:
|
||||
ydl = _build_youtube_dl(worker, tempdir, site, page)
|
||||
ie_result = _try_youtube_dl(worker, ydl, site, page)
|
||||
outlinks = set()
|
||||
|
Loading…
x
Reference in New Issue
Block a user