ytdl-org / youtube-dl

Command-line program to download videos from YouTube.com and other video sites
http://ytdl-org.github.io/youtube-dl/
The Unlicense
132.59k stars 10.05k forks source link

Recent archived content from YouTube livestreams only keeps small fragment after downloading. #24002

Closed CanOfColliders closed 4 years ago

CanOfColliders commented 4 years ago

Checklist

Verbose log

$ youtube-dl -v "https://www.youtube.com/watch?v=Va9vbM4EXbM" 
[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: [u'-v', u'https://www.youtube.com/watch?v=Va9vbM4EXbM']
[debug] Encodings: locale UTF-8, fs UTF-8, out None, pref UTF-8
[debug] youtube-dl version 2020.01.24
[debug] Python version 2.7.16 (CPython) - Linux-4.4.190-x86_64-AMD_Ryzen_7_1700_Eight-Core_Processor-with-slackware-14.2
[debug] exe versions: ffmpeg 3.2.4, ffprobe 3.2.4, rtmpdump 2.4
[debug] Proxy map: {}
[youtube] Va9vbM4EXbM: Downloading webpage
[youtube] Va9vbM4EXbM: Downloading video info webpage
[youtube] Va9vbM4EXbM: Downloading m3u8 information
[youtube] Va9vbM4EXbM: Downloading MPD manifest
[debug] Default format spec: bestvideo+bestaudio/best
[debug] Invoking downloader on u'https://manifest.googlevideo.com/api/manifest/dash/expire/1581252443/ei/-6o_XqnJGpS91gLa7aGgAw/ip/91.14.91.11/id/Va9vbM4EXbM.1/source/yt_live_broadcast/requiressl/yes/as/fmp4_audio_clear%2Cwebm_audio_clear%2Cwebm2_audio_clear%2Cfmp4_sd_hd_clear%2Cwebm2_sd_hd_clear/force_finished/1/vprv/1/keepalive/yes/fexp/23842630/itag/0/playlist_type/DVR/sparams/expire%2Cei%2Cip%2Cid%2Csource%2Crequiressl%2Cas%2Cforce_finished%2Cvprv%2Citag%2Cplaylist_type/sig/ALgxI2wwRAIgXpIhI0XOq5gduYtxE8BL5XoD1kzoij2JSmpzQaa7Of4CIFr1VhHmKCs86SjyLB5wYXepRUGlGgyDc1OtTD-oCKZw'
[dashsegments] Total fragments: 766
[download] Destination: PIA Executives Give THEIR Side of the Story - WAN Show Feb 7, 2020-Va9vbM4EXbM.f137.mp4
[download] 100% of 872.15MiB in 06:46
[debug] Invoking downloader on u'https://manifest.googlevideo.com/api/manifest/dash/expire/1581252443/ei/-6o_XqnJGpS91gLa7aGgAw/ip/91.14.91.11/id/Va9vbM4EXbM.1/source/yt_live_broadcast/requiressl/yes/as/fmp4_audio_clear%2Cwebm_audio_clear%2Cwebm2_audio_clear%2Cfmp4_sd_hd_clear%2Cwebm2_sd_hd_clear/force_finished/1/vprv/1/keepalive/yes/fexp/23842630/itag/0/playlist_type/DVR/sparams/expire%2Cei%2Cip%2Cid%2Csource%2Crequiressl%2Cas%2Cforce_finished%2Cvprv%2Citag%2Cplaylist_type/sig/ALgxI2wwRAIgXpIhI0XOq5gduYtxE8BL5XoD1kzoij2JSmpzQaa7Of4CIFr1VhHmKCs86SjyLB5wYXepRUGlGgyDc1OtTD-oCKZw'
[dashsegments] Total fragments: 766
[download] Destination: PIA Executives Give THEIR Side of the Story - WAN Show Feb 7, 2020-Va9vbM4EXbM.f140.m4a
[download] 100% of 59.32MiB in 02:01
[ffmpeg] Merging formats into "PIA Executives Give THEIR Side of the Story - WAN Show Feb 7, 2020-Va9vbM4EXbM.mp4"
[debug] ffmpeg command line: ffmpeg -y -loglevel 'repeat+info' -i 'file:PIA Executives Give THEIR Side of the Story - WAN Show Feb 7, 2020-Va9vbM4EXbM.f137.mp4' -i 'file:PIA Executives Give THEIR Side of the Story - WAN Show Feb 7, 2020-Va9vbM4EXbM.f140.m4a' -c copy -map '0:v:0' -map '1:a:0' 'file:PIA Executives Give THEIR Side of the Story - WAN Show Feb 7, 2020-Va9vbM4EXbM.temp.mp4'
Deleting original file PIA Executives Give THEIR Side of the Story - WAN Show Feb 7, 2020-Va9vbM4EXbM.f137.mp4 (pass -k to keep)
Deleting original file PIA Executives Give THEIR Side of the Story - WAN Show Feb 7, 2020-Va9vbM4EXbM.f140.m4a (pass -k to keep)
$ du -sh *.mp4
1.3M    PIA Executives Give THEIR Side of the Story - WAN Show Feb 7, 2020-Va9vbM4EXbM.mp4

Description

Noticed that recently i only end up with tiny fractions of archived livestreams on YouTube.

It does download the entire thing. Fragment after fragment, the file gets bigger. Once it's finished, only a small file is left.

Here is an example:

youtube-dl "https://www.youtube.com/watch?v=Va9vbM4EXbM"

Downloads 900MB+ video/audio, resulting file ends with 1.3MB (last ~5 seconds of the video).

Tested it with a few videos, and it only seems to happen with archived livestreams, and only recent ones.

(Not absolutely sure on this, but i could not find a recently uploaded video where this happened that wasn't originally streamed to youtube.)

remitamine commented 4 years ago

update FFmpeg to the latest version(4.2.2).