skip live streams

This commit is contained in:
Barbara Miller 2022-04-03 17:50:27 -07:00
parent 70bb544389
commit b693b8713f

View file

@ -18,6 +18,7 @@ limitations under the License.
import logging import logging
import yt_dlp as youtube_dl import yt_dlp as youtube_dl
from yt_dlp.utils import match_filter_func
import brozzler import brozzler
import urllib.request import urllib.request
import tempfile import tempfile
@ -249,6 +250,8 @@ def _build_youtube_dl(worker, destdir, site):
# "ext: Equivalent to vext,aext" # "ext: Equivalent to vext,aext"
"format_sort": ["ext"], "format_sort": ["ext"],
"format": "b/bv+ba", "format": "b/bv+ba",
# skip live streams
"match_filter": match_filter_func("!is_live"),
# --cache-dir local or... # --cache-dir local or...
"cache_dir": False, "cache_dir": False,