]> jfr.im git - yt-dlp.git/blobdiff - yt_dlp/__init__.py
Native concurrent downloading of fragments (#166)
[yt-dlp.git] / yt_dlp / __init__.py
index b8b8495e6f3cb40da6e30e60ccb36d983564c18f..55b962be1225fda4546720a7e0d00fda5ff8dd0e 100644 (file)
@@ -180,6 +180,8 @@ def _real_main(argv=None):
     if opts.overwrites:
         # --yes-overwrites implies --no-continue
         opts.continue_dl = False
+    if opts.concurrent_fragment_downloads <= 0:
+        raise ValueError('Concurrent fragments must be positive')
 
     def parse_retries(retries, name=''):
         if retries in ('inf', 'infinite'):
@@ -463,6 +465,7 @@ def report_args_compat(arg, name):
         'extractor_retries': opts.extractor_retries,
         'skip_unavailable_fragments': opts.skip_unavailable_fragments,
         'keep_fragments': opts.keep_fragments,
+        'concurrent_fragment_downloads': opts.concurrent_fragment_downloads,
         'buffersize': opts.buffersize,
         'noresizebuffer': opts.noresizebuffer,
         'http_chunk_size': opts.http_chunk_size,