Skip to content

FFMPEG "Invalid data found when processing input" on live/post-live/dash videos (duplicate ftyp) #8641

@richardstevenhack

Description

@richardstevenhack

DO NOT REMOVE OR SKIP THE ISSUE TEMPLATE

  • I understand that I will be blocked if I intentionally remove or skip any mandatory* field

Checklist

Region

United States

Provide a description that is worded well enough to be understood

I am running openSUSE Tumbleweed on snapshot dated 20231121.

I attempted to download the video at this URL from Youtube:
https://www.youtube.com/watch?v=-Cy4xFMeOxo

This is a live stream video which aired 11 hours before the download attempt.

The download appeared to go fine as shown by the verbose output below, but on post processing by FFMPEG, it reported the following:
yt_dlp.postprocessor.ffmpeg.FFmpegPostProcessorError: file:Ninjutsu Training Mind-Control | Warrior's Whiteboard Wed [-Cy4xFMeOxo].f140.m4a: Invalid data found when processing input

Provide verbose output that clearly demonstrates the problem

  • Run your yt-dlp command with -vU flag added (yt-dlp -vU <your command line>)
  • If using API, add 'verbose': True to YoutubeDL params instead
  • Copy the WHOLE output (starting with [debug] Command-line config) and insert it below

Complete Verbose Output

[debug] Command-line config: ['-vU', 'https://www.youtube.com/watch?v=-Cy4xFMeOxo']
[debug] Encodings: locale UTF-8, fs utf-8, pref UTF-8, out utf-8, error utf-8, screen utf-8
[debug] yt-dlp version stable@2023.11.16 from yt-dlp/yt-dlp [24f827875]
[debug] Lazy loading extractors is disabled
[debug] Python 3.11.5 (CPython x86_64 64bit) - Linux-6.6.2-1-default-x86_64-with-glibc2.38 (OpenSSL 3.1.4 24 Oct 2023, glibc 2.38)
[debug] exe versions: ffmpeg 6.0.1 (setts), ffprobe 6.0.1
[debug] Optional libraries: Cryptodome-3.19.0, brotli-1.1.0, certifi-2023.07.22, mutagen-1.47.0, requests-2.31.0, sqlite3-3.44.0, urllib3-2.1.0, websockets-12.0
[debug] Proxy map: {}
[debug] Request Handlers: urllib, requests, websockets
[debug] Loaded 1915 extractors
[debug] Fetching release info: https://api.github.com/repos/yt-dlp/yt-dlp/releases/latest
Latest version: stable@2023.11.16 from yt-dlp/yt-dlp
yt-dlp is up to date (stable@2023.11.16 from yt-dlp/yt-dlp)
[youtube] Extracting URL: https://www.youtube.com/watch?v=-Cy4xFMeOxo
[youtube] -Cy4xFMeOxo: Downloading webpage
[youtube] -Cy4xFMeOxo: Downloading ios player API JSON
[youtube] -Cy4xFMeOxo: Downloading android player API JSON
[youtube] -Cy4xFMeOxo: Downloading m3u8 information
[youtube] -Cy4xFMeOxo: Downloading m3u8 information
[youtube] -Cy4xFMeOxo: Downloading MPD manifest
[youtube] -Cy4xFMeOxo: Downloading m3u8 information
[youtube] -Cy4xFMeOxo: Downloading MPD manifest
[debug] [youtube] -Cy4xFMeOxo: Video is in Post-Live Manifestless mode
[debug] Sort order given by extractor: quality, res, fps, hdr:12, source, vcodec:vp9.2, channels, acodec, lang, proto
[debug] Formats sorted by: hasvid, ie_pref, quality, res, fps, hdr:12(7), source, vcodec:vp9.2(10), channels, acodec, lang, proto, size, br, asr, vext, aext, hasaud, id
[debug] Default format spec: bestvideo*+bestaudio/best
[info] -Cy4xFMeOxo: Downloading 1 format(s): 248+140
[debug] Invoking dashsegments downloader on "https://manifest.googlevideo.com/api/manifest/dash/expire/1700745946/ei/ev5eZfKQOb3HsfIPxb6dyAY/ip/2601%3A645%3A8900%3Af0f0%3A%3A963b/id/-Cy4xFMeOxo.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/spc/UWF9f-6AVoxcnBSoHfY4fhQLn4tm0ak/vprv/1/pacing/0/itag_bl/376%2C377%2C384%2C385%2C612%2C613%2C617%2C619%2C623%2C628%2C655%2C656%2C660%2C662%2C666%2C671/keepalive/yes/fexp/24007246/itag/0/playlist_type/DVR/sparams/expire%2Cei%2Cip%2Cid%2Csource%2Crequiressl%2Cas%2Cforce_finished%2Cspc%2Cvprv%2Citag%2Cplaylist_type/sig/ANLwegAwRgIhAJyjGc6ab2Ry_kijQfy6hEebmqL58ECkLp2eozd5WY5sAiEAsSJmjCTECdoQLZoF8z5FEGeEVlP9AUYqlIFlqMRIF7w%3D"
[dashsegments] Total fragments: 1806
[download] Destination: Ninjutsu Training Mind-Control | Warrior's Whiteboard Wed [-Cy4xFMeOxo].f248.webm
[download] 100% of  466.62MiB in 00:01:42 at 4.54MiB/s
[debug] Invoking dashsegments downloader on "https://manifest.googlevideo.com/api/manifest/dash/expire/1700745946/ei/ev5eZfKQOb3HsfIPxb6dyAY/ip/2601%3A645%3A8900%3Af0f0%3A%3A963b/id/-Cy4xFMeOxo.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/spc/UWF9f-6AVoxcnBSoHfY4fhQLn4tm0ak/vprv/1/pacing/0/itag_bl/376%2C377%2C384%2C385%2C612%2C613%2C617%2C619%2C623%2C628%2C655%2C656%2C660%2C662%2C666%2C671/keepalive/yes/fexp/24007246/itag/0/playlist_type/DVR/sparams/expire%2Cei%2Cip%2Cid%2Csource%2Crequiressl%2Cas%2Cforce_finished%2Cspc%2Cvprv%2Citag%2Cplaylist_type/sig/ANLwegAwRgIhAJyjGc6ab2Ry_kijQfy6hEebmqL58ECkLp2eozd5WY5sAiEAsSJmjCTECdoQLZoF8z5FEGeEVlP9AUYqlIFlqMRIF7w%3D"
[dashsegments] Total fragments: 1806
[download] Destination: Ninjutsu Training Mind-Control | Warrior's Whiteboard Wed [-Cy4xFMeOxo].f140.m4a
[download] 100% of   72.88MiB in 00:01:24 at 879.22KiB/s
[Merger] Merging formats into "Ninjutsu Training Mind-Control | Warrior's Whiteboard Wed [-Cy4xFMeOxo].mkv"
[debug] ffmpeg command line: ffmpeg -y -loglevel repeat+info -i 'file:Ninjutsu Training Mind-Control | Warrior'"'"'s Whiteboard Wed [-Cy4xFMeOxo].f248.webm' -i 'file:Ninjutsu Training Mind-Control | Warrior'"'"'s Whiteboard Wed [-Cy4xFMeOxo].f140.m4a' -c copy -map 0:v:0 -map 1:a:0 -movflags +faststart 'file:Ninjutsu Training Mind-Control | Warrior'"'"'s Whiteboard Wed [-Cy4xFMeOxo].temp.mkv'
[debug] ffmpeg version 6.0.1 Copyright (c) 2000-2023 the FFmpeg developers
  built with gcc 13 (SUSE Linux)
  configuration: --prefix=/usr --libdir=/usr/lib64 --shlibdir=/usr/lib64 --incdir=/usr/include/ffmpeg --extra-cflags='-O2 -Wall -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=3 -fstack-protector-strong -funwind-tables -fasynchronous-unwind-tables -fstack-clash-protection -Werror=return-type -flto=auto -ffat-lto-objects -g' --optflags='-O2 -Wall -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=3 -fstack-protector-strong -funwind-tables -fasynchronous-unwind-tables -fstack-clash-protection -Werror=return-type -flto=auto -ffat-lto-objects -g' --disable-htmlpages --enable-pic --disable-stripping --enable-shared --disable-static --enable-gpl --enable-version3 --disable-openssl --enable-gnutls --enable-ladspa --enable-libshaderc --enable-vulkan --enable-libplacebo --disable-cuda-sdk --enable-libaom --enable-libass --enable-libbluray --enable-libbs2b --enable-libcdio --enable-libcodec2 --enable-libdav1d --enable-libdc1394 --enable-libdrm --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-libgsm --enable-libjack --enable-libjxl --enable-librist --enable-libmp3lame --enable-libmysofa --enable-libopenjpeg --enable-libopenmpt --enable-libopenh264-dlopen --enable-libopus --enable-libpulse --enable-librav1e --enable-librubberband --enable-libsvtav1 --enable-libsoxr --enable-libspeex --enable-libssh --enable-libsrt --enable-libtheora --enable-libtwolame --enable-libvidstab --enable-libvmaf --enable-libvorbis --enable-libvpx --enable-libwebp --enable-libxml2 --enable-libzimg --enable-libzmq --enable-libzvbi --enable-lto --enable-lv2 --enable-libmfx --enable-vaapi --enable-vdpau --enable-version3 --enable-muxers --enable-demuxers --disable-encoders --disable-decoders --disable-decoder='mpeg4,h263,h264,hevc,vc1' --enable-encoder=',aac,apng,ass,ayuv,bmp,ffv1,ffvhuff,flac,gif,huffyuv,jpegls,libaom,libaom_av1,libcodec2,libgsm,libjxl,libmp3lame,libopenh264,libopenjpeg,libopus,librav1e,libschroedinger,libspeex,libsvtav1,libtheora,libtwolame,libvorbis,libvpx_vp8,libvpx_vp9,libwebp,libwebp_anim,mjpeg,mp2,mp2fixed,mpeg1video,mpeg2video,opus,pam,pbm,pcm_alaw,pcm_f32be,pcm_f32le,pcm_f64be,pcm_f64le,pcm_mulaw,pcm_s16be,pcm_s16be_planar,pcm_s16le,pcm_s16le_planar,pcm_s24be,pcm_s24le,pcm_s24le_planar,pcm_s32be,pcm_s32le,pcm_s32le_planar,pcm_s8,pcm_s8_planar,pcm_u16be,pcm_u16le,pcm_u24be,pcm_u24le,pcm_u32be,pcm_u32le,pcm_u8,pcx,pgm,pgmyuv,png,ppm,rawvideo,sgi,srt,ssa,sunrast,targa,text,tiff,v210,v308,v408,v410,vorbis,webvtt,wrapped_avframe,xbm,xwd,y41p,yuv4,zlib,' --enable-decoder=',aac,ac3,ansi,apng,ass,ayuv,bmp,dirac,exr,ffv1,ffvhuff,ffwavesynth,flac,gif,gsm,huffyuv,ilbc,libaom,libaom_av1,libcodec2,libdav1d,libgsm,libopenh264,libopenjpeg,libopus,libschroedinger,libspeex,libvorbis,libvpx_vp8,libvpx_vp9,mjpeg,mp1,mp1float,mp2,mp2float,mp3,mp3float,mpeg1video,mpeg2video,,opus,pam,pbm,pcm_alaw,pcm_bluray,pcm_dvd,pcm_f32be,pcm_f32le,pcm_f64be,pcm_f64le,pcm_mulaw,pcm_s16be,pcm_s16be_planar,pcm_s16le,pcm_s16le_planar,pcm_s24be,pcm_s24le,pcm_s24le_planar,pcm_s32be,pcm_s32le,pcm_s32le_planar,pcm_s8,pcm_s8_planar,pcm_u16be,pcm_u16le,pcm_u24be,pcm_u24le,pcm_u32be,pcm_u32le,pcm_u8,pcx,pgm,pgmyuv,pgssub,png,ppm,rawvideo,sgi,srt,ssa,sunrast,targa,text,theora,tiff,v210,v210x,v308,v408,v410,vorbis,vp3,vp5,vp6,vp6a,vp6f,vp8,vp9,webp,webvtt,wrapped_avframe,xbm,xwd,y41p,yuv4,zlib,'
  libavutil      58.  2.100 / 58.  2.100
  libavcodec     60.  3.100 / 60.  3.100
  libavformat    60.  3.100 / 60.  3.100
  libavdevice    60.  1.100 / 60.  1.100
  libavfilter     9.  3.100 /  9.  3.100
  libswscale      7.  1.100 /  7.  1.100
  libswresample   4. 10.100 /  4. 10.100
  libpostproc    57.  1.100 / 57.  1.100
Input #0, matroska,webm, from 'file:Ninjutsu Training Mind-Control | Warrior's Whiteboard Wed [-Cy4xFMeOxo].f248.webm':
  Metadata:
    encoder         : google/video-file
    http://youtube.com/streaming/metadata/segment/102015: Sequence-Number: 0 
                    : Ingestion-Walltime-Us: 1700683384160270 
                    : Ingestion-Uncertainty-Us: 73 
                    : Stream-Duration-Us: 0 
                    : Max-Dvr-Duration-Us: 7200000000 
                    : Target-Duration-Us: 2000000 
                    : Streamable: T 
                    : First-Frame-Time-Us: 1700683387518007 
                    : First-Frame-Uncertainty-Us: 87 
                    :  
                    : 
  Duration: N/A, start: 0.000000, bitrate: N/A
  Stream #0:0(eng): Video: vp9 (Profile 0), yuv420p(tv, bt709), 1920x1080, SAR 1:1 DAR 16:9, 30 fps, 30 tbr, 1k tbn (default)
[mov,mp4,m4a,3gp,3g2,mj2 @ 0x55c7c01b4f00] error reading header
file:Ninjutsu Training Mind-Control | Warrior's Whiteboard Wed [-Cy4xFMeOxo].f140.m4a: Invalid data found when processing input

ERROR: Postprocessing: file:Ninjutsu Training Mind-Control | Warrior's Whiteboard Wed [-Cy4xFMeOxo].f140.m4a: Invalid data found when processing input
Traceback (most recent call last):
  File "/home/rhack/.local/pipx/venvs/yt-dlp/lib64/python3.11/site-packages/yt_dlp/YoutubeDL.py", line 3468, in process_info
    replace_info_dict(self.post_process(dl_filename, info_dict, files_to_move))
                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/rhack/.local/pipx/venvs/yt-dlp/lib64/python3.11/site-packages/yt_dlp/YoutubeDL.py", line 3648, in post_process
    info = self.run_all_pps('post_process', info, additional_pps=info.get('__postprocessors'))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/rhack/.local/pipx/venvs/yt-dlp/lib64/python3.11/site-packages/yt_dlp/YoutubeDL.py", line 3630, in run_all_pps
    info = self.run_pp(pp, info)
           ^^^^^^^^^^^^^^^^^^^^^
  File "/home/rhack/.local/pipx/venvs/yt-dlp/lib64/python3.11/site-packages/yt_dlp/YoutubeDL.py", line 3608, in run_pp
    files_to_delete, infodict = pp.run(infodict)
                                ^^^^^^^^^^^^^^^^
  File "/home/rhack/.local/pipx/venvs/yt-dlp/lib64/python3.11/site-packages/yt_dlp/postprocessor/common.py", line 23, in run
    ret = func(self, info, *args, **kwargs)
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/rhack/.local/pipx/venvs/yt-dlp/lib64/python3.11/site-packages/yt_dlp/postprocessor/common.py", line 128, in wrapper
    return func(self, info)
           ^^^^^^^^^^^^^^^^
  File "/home/rhack/.local/pipx/venvs/yt-dlp/lib64/python3.11/site-packages/yt_dlp/postprocessor/ffmpeg.py", line 837, in run
    self.run_ffmpeg_multiple_files(info['__files_to_merge'], temp_filename, args)
  File "/home/rhack/.local/pipx/venvs/yt-dlp/lib64/python3.11/site-packages/yt_dlp/postprocessor/ffmpeg.py", line 329, in run_ffmpeg_multiple_files
    return self.real_run_ffmpeg(
           ^^^^^^^^^^^^^^^^^^^^^
  File "/home/rhack/.local/pipx/venvs/yt-dlp/lib64/python3.11/site-packages/yt_dlp/postprocessor/ffmpeg.py", line 367, in real_run_ffmpeg
    raise FFmpegPostProcessorError(stderr.strip().splitlines()[-1])
yt_dlp.postprocessor.ffmpeg.FFmpegPostProcessorError: file:Ninjutsu Training Mind-Control | Warrior's Whiteboard Wed [-Cy4xFMeOxo].f140.m4a: Invalid data found when processing input

Metadata

Metadata

Assignees

No one assigned

    Labels

    external issueIssue with an external tool or site

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions