ERROR: Postprocessing: Conversion failed! (yt_dlp.postprocessor.ffmpeg.FFmpegPostProcessorError)

See original GitHub issue

Checklist

  • I’m reporting a bug unrelated to a specific site
  • I’ve verified that I’m running yt-dlp version 2021.09.02
  • I’ve checked that all provided URLs are alive and playable in a browser
  • The provided URLs do not contain any DRM to the best of my knowledge
  • I’ve checked that all URLs and arguments with special characters are properly quoted or escaped
  • I’ve searched the bugtracker for similar bug reports including closed ones
  • I’ve read bugs section in FAQ

Verbose log

[debug] Custom config file: /config/args.conf
[debug] Custom config: ['--sponsorblock-mark', 'all', '--sponsorblock-remove', 'sponsor', '--output', '/downloads/%(uploader)s/%(title)s.%(ext)s', '--geo-bypass', '--playlist-end', '1', '--match-filter', '! is_live', '--abort-on-unavailable-fragment', '--playlist-reverse', '--windows-filenames', '--no-part', '--no-write-playlist-metafiles', '--no-cache-dir', '--cookies', '/config/cookies.txt', '--no-progress', '--merge-output-format', 'mp4', '--sub-langs', 'all,-live_chat', '--embed-subs', '--embed-thumbnail', '--add-metadata', '--convert-subs', 'srt']
[debug] Command-line config: ['--verbose', '--download-archive', '/config/archive.txt', '--config-location', '/config/args.conf', '--batch-file', '/config/channels.txt', '--format', '((bv*[fps>30]/bv*)[height<=1440]/(wv*[fps>30]/wv*)) + ba / (b[fps>30]/b)[height<=1440]/(w[fps>30]/w)']
[debug] Batch file urls: ['https://www.youtube.com/watch?v=8NK1I6S_vFs']
[debug] Loading archive file '/config/archive.txt'

[debug] Encodings: locale UTF-8, fs utf-8, out utf-8, pref UTF-8
[debug] yt-dlp version 2021.09.02 (zip)
[debug] Python version 3.9.5 (CPython 64bit) - Linux-5.4.0-74-generic-x86_64-with
[debug] exe versions: ffmpeg 4.4, ffprobe 4.4
[debug] Optional libraries: mutagen, sqlite
[debug] Proxy map: {}
[debug] [youtube] Extracting URL: https://www.youtube.com/watch?v=8NK1I6S_vFs
[youtube] 8NK1I6S_vFs: Downloading webpage
[debug] [youtube] Extracted SAPISID cookie
[youtube] 8NK1I6S_vFs: Downloading android player API JSON
[debug] Sort order given by extractor: quality, res, fps, source, codec:vp9.2, lang
[debug] Formats sorted by: hasvid, ie_pref, quality, res, fps, source, vcodec:vp9.2(10), acodec, lang, filesize, fs_approx, tbr, vbr, abr, asr, proto, vext, aext, hasaud, id
[debug] Testing thumbnail 41
[debug] SponsorBlock query: https://sponsor.ajay.app/api/skipSegments/4c28?service=YouTube&categories=%5B%22sponsor%22%2C+%22music_offtopic%22%2C+%22interaction%22%2C+%22intro%22%2C+%22outro%22%2C+%22preview%22%2C+%22selfpromo%22%5D
[SponsorBlock] Found 5 segments in the SponsorBlock database
[info] 8NK1I6S_vFs: Downloading 1 format(s): 271+251
[debug] Testing thumbnail 39
[debug] Testing thumbnail 38
[debug] Testing thumbnail 37
[debug] Testing thumbnail 35
[debug] Testing thumbnail 34
[debug] Testing thumbnail 33
[debug] Testing thumbnail 32
[debug] Testing thumbnail 31
[debug] Testing thumbnail 30
[youtube] 8NK1I6S_vFs: Downloading thumbnail  ...
[youtube] 8NK1I6S_vFs: Writing thumbnail to: /downloads/Linus Tech Tips/Steam Deck Competitors are ALREADY Here.webp
[SubtitlesConvertor] There aren't any subtitles to convert
[debug] Invoking downloader on "https://r8---sn-uxaxovg-5god.googlevideo.com/videoplayback?expire=1630603835&ei=27UwYZGmC8v--gbGobzYAQ&ip=85.225.40.88&id=o-AOILCfE0RbSHRvT1V98oGy8PPbC6ap4haHXQEVrQfXHy&itag=271&source=youtube&requiressl=yes&mh=oq&mm=31%2C29&mn=sn-uxaxovg-5god%2Csn-5go7yne6&ms=au%2Crdu&mv=m&mvi=8&pl=22&pcm2=yes&initcwndbps=1920000&vprv=1&mime=video%2Fwebm&gir=yes&clen=584543772&dur=1132.398&lmt=1630531523085979&mt=1630581886&fvip=4&keepalive=yes&fexp=24001373%2C24007246&c=ANDROID&txp=5516222&sparams=expire%2Cei%2Cip%2Cid%2Citag%2Csource%2Crequiressl%2Cpcm2%2Cvprv%2Cmime%2Cgir%2Cclen%2Cdur%2Clmt&sig=AOq0QJ8wRAIhAPeb1ffaBEIwaYSEtJOK67z3voPJmScdFH7ycohP6EaPAh9rCfsMgZEhJ02OVh_jlIBbgJb0vqQW9tTujNKJO9IP&lsparams=mh%2Cmm%2Cmn%2Cms%2Cmv%2Cmvi%2Cpl%2Cinitcwndbps&lsig=AG3C_xAwRQIgabFH0Tj6do15NP9-nw6o-42xGRTAHZrlMEJ-Aee0jb0CIQD95PzdhTYfJGYfeLPdUEBhyR3mss_plQY-KXcIjIJc2w%3D%3D"
[download] Destination: /downloads/Linus Tech Tips/Steam Deck Competitors are ALREADY Here.f271.webm
[download] Download completed
[debug] Invoking downloader on "https://r8---sn-uxaxovg-5god.googlevideo.com/videoplayback?expire=1630603835&ei=27UwYZGmC8v--gbGobzYAQ&ip=85.225.40.88&id=o-AOILCfE0RbSHRvT1V98oGy8PPbC6ap4haHXQEVrQfXHy&itag=251&source=youtube&requiressl=yes&mh=oq&mm=31%2C29&mn=sn-uxaxovg-5god%2Csn-5go7yne6&ms=au%2Crdu&mv=m&mvi=8&pl=22&pcm2=yes&initcwndbps=1920000&vprv=1&mime=audio%2Fwebm&gir=yes&clen=15174355&dur=1132.441&lmt=1630531497030616&mt=1630581886&fvip=4&keepalive=yes&fexp=24001373%2C24007246&c=ANDROID&txp=5511222&sparams=expire%2Cei%2Cip%2Cid%2Citag%2Csource%2Crequiressl%2Cpcm2%2Cvprv%2Cmime%2Cgir%2Cclen%2Cdur%2Clmt&sig=AOq0QJ8wRQIhAMM-jf-RLDEddjOAZ-G1i4EdzDPVksMQPbXJ2wHsWD9_AiBJt-P8Ac7vM3hJEeyJRyHcscRBo-Z9WbQEz1LE01Y5Iw%3D%3D&lsparams=mh%2Cmm%2Cmn%2Cms%2Cmv%2Cmvi%2Cpl%2Cinitcwndbps&lsig=AG3C_xAwRQIgabFH0Tj6do15NP9-nw6o-42xGRTAHZrlMEJ-Aee0jb0CIQD95PzdhTYfJGYfeLPdUEBhyR3mss_plQY-KXcIjIJc2w%3D%3D"
[download] Destination: /downloads/Linus Tech Tips/Steam Deck Competitors are ALREADY Here.f251.webm
[download] Download completed
[Merger] Merging formats into "/downloads/Linus Tech Tips/Steam Deck Competitors are ALREADY Here.mp4"
[debug] ffmpeg command line: ffmpeg -y -loglevel repeat+info -i 'file:/downloads/Linus Tech Tips/Steam Deck Competitors are ALREADY Here.f271.webm' -i 'file:/downloads/Linus Tech Tips/Steam Deck Competitors are ALREADY Here.f251.webm' -c copy -map 0:v:0 -map 1:a:0 'file:/downloads/Linus Tech Tips/Steam Deck Competitors are ALREADY Here.temp.mp4'
Deleting original file /downloads/Linus Tech Tips/Steam Deck Competitors are ALREADY Here.f271.webm (pass -k to keep)
Deleting original file /downloads/Linus Tech Tips/Steam Deck Competitors are ALREADY Here.f251.webm (pass -k to keep)
[EmbedSubtitle] There aren't any subtitles to embed
[debug] ffprobe command line: ffprobe -hide_banner -show_format -show_streams -print_format json 'file:/downloads/Linus Tech Tips/Steam Deck Competitors are ALREADY Here.mp4'
[debug] Writing concat spec to /downloads/Linus Tech Tips/Steam Deck Competitors are ALREADY Here.temp.mp4.concat
[ModifyChapters] Removing chapters from /downloads/Linus Tech Tips/Steam Deck Competitors are ALREADY Here.mp4
[debug] ffmpeg command line: ffmpeg -y -loglevel repeat+info -hide_banner -nostdin -f concat -safe 0 -i 'file:/downloads/Linus Tech Tips/Steam Deck Competitors are ALREADY Here.temp.mp4.concat' -c copy -c:s mov_text -movflags +faststart 'file:/downloads/Linus Tech Tips/Steam Deck Competitors are ALREADY Here.temp.mp4'
ERROR: Input #0, concat, from 'file:/downloads/Linus Tech Tips/Steam Deck Competitors are ALREADY Here.temp.mp4.concat':
  Duration: N/A, start: 0.000000, bitrate: 4232 kb/s
  Stream #0:0(eng): Video: vp9 (Profile 0) (vp09 / 0x39307076), yuv420p(tv, bt709), 2560x1280, 4127 kb/s, SAR 1:1 DAR 2:1, 29.97 fps, 29.97 tbr, 16k tbn, 16k tbc
    Metadata:
      handler_name    : VideoHandler
      vendor_id       : [0][0][0][0]
  Stream #0:1(eng): Audio: opus (Opus / 0x7375704F), 48000 Hz, stereo, fltp, 104 kb/s
    Metadata:
      handler_name    : SoundHandler
      vendor_id       : [0][0][0][0]
[mp4 @ 0x7f7ec228d100] track 1: codec frame size is not set
Output #0, mp4, to 'file:/downloads/Linus Tech Tips/Steam Deck Competitors are ALREADY Here.temp.mp4':
  Metadata:
    encoder         : Lavf58.76.100
  Stream #0:0(eng): Video: vp9 (Profile 0) (vp09 / 0x39307076), yuv420p(tv, bt709), 2560x1280 [SAR 1:1 DAR 2:1], q=2-31, 4127 kb/s, 29.97 fps, 29.97 tbr, 16k tbn, 16k tbc
    Metadata:
      handler_name    : VideoHandler
      vendor_id       : [0][0][0][0]
  Stream #0:1(eng): Audio: opus (Opus / 0x7375704F), 48000 Hz, stereo, fltp, 104 kb/s
    Metadata:
      handler_name    : SoundHandler
      vendor_id       : [0][0][0][0]
Stream mapping:
  Stream #0:0 -> #0:0 (copy)
  Stream #0:1 -> #0:1 (copy)
[mp4 @ 0x7f7ec228d100] Non-monotonous DTS in output stream 0:1; previous: 2949168, current: 2941824; changing to 2949169. This may result in incorrect timestamps in the output file.
[concat @ 0x7f7ec3771640] DTS 980816 < 982848 out of order
[mp4 @ 0x7f7ec228d100] Application provided invalid, non monotonically increasing dts to muxer in stream 0: 982848 >= 980816
av_interleaved_write_frame(): Invalid argument
[mp4 @ 0x7f7ec228d100] Starting second pass: moving the moov atom to the beginning of the file
frame= 1843 fps=0.0 q=-1.0 Lsize=   36332kB time=00:01:01.44 bitrate=4844.2kbits/s speed=64.7x
video:35425kB audio:853kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.149294%
Conversion failed!
  File "/usr/lib/python3.9/runpy.py", line 197, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "/usr/lib/python3.9/runpy.py", line 87, in _run_code
    exec(code, run_globals)
  File "/usr/bin/yt-dlp/__main__.py", line 19, in <module>
    yt_dlp.main()
  File "/usr/bin/yt-dlp/yt_dlp/__init__.py", line 776, in main
    _real_main(argv)
  File "/usr/bin/yt-dlp/yt_dlp/__init__.py", line 766, in _real_main
    retcode = ydl.download(all_urls)
  File "/usr/bin/yt-dlp/yt_dlp/YoutubeDL.py", line 2894, in download
    res = self.extract_info(
  File "/usr/bin/yt-dlp/yt_dlp/YoutubeDL.py", line 1207, in extract_info
    return self.__extract_info(url, self.get_info_extractor(ie_key), download, extra_info, process)
  File "/usr/bin/yt-dlp/yt_dlp/YoutubeDL.py", line 1214, in wrapper
    return func(self, *args, **kwargs)
  File "/usr/bin/yt-dlp/yt_dlp/YoutubeDL.py", line 1252, in __extract_info
    return self.process_ie_result(ie_result, download, extra_info)
  File "/usr/bin/yt-dlp/yt_dlp/YoutubeDL.py", line 1298, in process_ie_result
    ie_result = self.process_video_result(ie_result, download=download)
  File "/usr/bin/yt-dlp/yt_dlp/YoutubeDL.py", line 2320, in process_video_result
    self.process_info(new_info)
  File "/usr/bin/yt-dlp/yt_dlp/YoutubeDL.py", line 2864, in process_info
    info_dict = self.post_process(dl_filename, info_dict, files_to_move)
  File "/usr/bin/yt-dlp/yt_dlp/YoutubeDL.py", line 3015, in post_process
    info = self.run_pp(pp, info)
  File "/usr/bin/yt-dlp/yt_dlp/YoutubeDL.py", line 2964, in run_pp
    files_to_delete, infodict = pp.run(infodict)
  File "/usr/bin/yt-dlp/yt_dlp/postprocessor/common.py", line 83, in wrapper
    return func(self, info)
  File "/usr/bin/yt-dlp/yt_dlp/postprocessor/modify_chapters.py", line 64, in run
    in_out_files = [remove_chapters(info['filepath'], False)]
  File "/usr/bin/yt-dlp/yt_dlp/postprocessor/modify_chapters.py", line 62, in remove_chapters
    return file, self.remove_chapters(file, cuts, concat_opts, self._force_keyframes and not is_sub)
  File "/usr/bin/yt-dlp/yt_dlp/postprocessor/modify_chapters.py", line 316, in remove_chapters
    self.concat_files([in_file] * len(concat_opts), out_file, concat_opts)
  File "/usr/bin/yt-dlp/yt_dlp/postprocessor/ffmpeg.py", line 332, in concat_files
    self.real_run_ffmpeg(
  File "/usr/bin/yt-dlp/yt_dlp/postprocessor/ffmpeg.py", line 274, in real_run_ffmpeg
    self.report_error(stderr)
  File "/usr/bin/yt-dlp/yt_dlp/postprocessor/common.py", line 56, in report_error
    return self._downloader.report_error(text, *args, **kwargs)
  File "/usr/bin/yt-dlp/yt_dlp/YoutubeDL.py", line 818, in report_error
    self.trouble(error_message, tb)
  File "/usr/bin/yt-dlp/yt_dlp/YoutubeDL.py", line 774, in trouble
    tb_data = traceback.format_list(traceback.extract_stack())

ERROR: Postprocessing: Conversion failed!
Traceback (most recent call last):
  File "/usr/bin/yt-dlp/yt_dlp/YoutubeDL.py", line 2864, in process_info
    info_dict = self.post_process(dl_filename, info_dict, files_to_move)
  File "/usr/bin/yt-dlp/yt_dlp/YoutubeDL.py", line 3015, in post_process
    info = self.run_pp(pp, info)
  File "/usr/bin/yt-dlp/yt_dlp/YoutubeDL.py", line 2964, in run_pp
    files_to_delete, infodict = pp.run(infodict)
  File "/usr/bin/yt-dlp/yt_dlp/postprocessor/common.py", line 83, in wrapper
    return func(self, info)
  File "/usr/bin/yt-dlp/yt_dlp/postprocessor/modify_chapters.py", line 64, in run
    in_out_files = [remove_chapters(info['filepath'], False)]
  File "/usr/bin/yt-dlp/yt_dlp/postprocessor/modify_chapters.py", line 62, in remove_chapters
    return file, self.remove_chapters(file, cuts, concat_opts, self._force_keyframes and not is_sub)
  File "/usr/bin/yt-dlp/yt_dlp/postprocessor/modify_chapters.py", line 316, in remove_chapters
    self.concat_files([in_file] * len(concat_opts), out_file, concat_opts)
  File "/usr/bin/yt-dlp/yt_dlp/postprocessor/ffmpeg.py", line 332, in concat_files
    self.real_run_ffmpeg(
  File "/usr/bin/yt-dlp/yt_dlp/postprocessor/ffmpeg.py", line 275, in real_run_ffmpeg
    raise FFmpegPostProcessorError(stderr.split('\n')[-1])
yt_dlp.postprocessor.ffmpeg.FFmpegPostProcessorError: Conversion failed!

Another url

[debug] Custom config file: /config/args.conf
[debug] Custom config: ['--sponsorblock-mark', 'all', '--sponsorblock-remove', 'sponsor', '--output', '/downloads/%(uploader)s/%(title)s.%(ext)s', '--geo-bypass', '--playlist-end', '1', '--match-filter', '! is_live', '--abort-on-unavailable-fragment', '--playlist-reverse', '--windows-filenames', '--no-part', '--no-write-playlist-metafiles', '--no-cache-dir', '--cookies', '/config/cookies.txt', '--no-progress', '--merge-output-format', 'mp4', '--sub-langs', 'all,-live_chat', '--embed-subs', '--embed-thumbnail', '--add-metadata', '--convert-subs', 'srt']
[debug] Command-line config: ['--verbose', '--download-archive', '/config/archive.txt', '--config-location', '/config/args.conf', '--batch-file', '/config/channels.txt', '--format', '((bv*[fps>30]/bv*)[height<=1440]/(wv*[fps>30]/wv*)) + ba / (b[fps>30]/b)[height<=1440]/(w[fps>30]/w)']
[debug] Batch file urls: ['https://www.youtube.com/watch?v=1uu9VWBgcBU']
[debug] Loading archive file '/config/archive.txt'

[debug] Encodings: locale UTF-8, fs utf-8, out utf-8, pref UTF-8
[debug] yt-dlp version 2021.09.02 (zip)
[debug] Python version 3.9.5 (CPython 64bit) - Linux-5.4.0-74-generic-x86_64-with
[debug] exe versions: ffmpeg 4.4, ffprobe 4.4
[debug] Optional libraries: mutagen, sqlite
[debug] Proxy map: {}
[debug] [youtube] Extracting URL: https://www.youtube.com/watch?v=1uu9VWBgcBU
[youtube] 1uu9VWBgcBU: Downloading webpage
[debug] [youtube] Extracted SAPISID cookie
[youtube] 1uu9VWBgcBU: Downloading android player API JSON
[debug] Sort order given by extractor: quality, res, fps, source, codec:vp9.2, lang
[debug] Formats sorted by: hasvid, ie_pref, quality, res, fps, source, vcodec:vp9.2(10), acodec, lang, filesize, fs_approx, tbr, vbr, abr, asr, proto, vext, aext, hasaud, id
[debug] Testing thumbnail 41
[debug] Downloading subtitles: en-US
[debug] SponsorBlock query: https://sponsor.ajay.app/api/skipSegments/de9c?service=YouTube&categories=%5B%22sponsor%22%2C+%22intro%22%2C+%22outro%22%2C+%22preview%22%2C+%22music_offtopic%22%2C+%22selfpromo%22%2C+%22interaction%22%5D
[SponsorBlock] Found 5 segments in the SponsorBlock database
[info] 1uu9VWBgcBU: Downloading 1 format(s): 271+251
...
[ModifyChapters] Removing chapters from /downloads/Marques Brownlee/Samsung Z Flip 3 Review - The First Big Step!.mp4
[debug] Writing concat spec to /downloads/Marques Brownlee/Samsung Z Flip 3 Review - The First Big Step!.temp.mp4.concat
[debug] ffmpeg command line: ffmpeg -y -loglevel repeat+info -hide_banner -nostdin -f concat -safe 0 -i 'file:/downloads/Marques Brownlee/Samsung Z Flip 3 Review - The First Big Step!.temp.mp4.concat' -c copy -c:s mov_text -movflags +faststart 'file:/downloads/Marques Brownlee/Samsung Z Flip 3 Review - The First Big Step!.temp.mp4'
ERROR: Input #0, concat, from 'file:/downloads/Marques Brownlee/Samsung Z Flip 3 Review - The First Big Step!.temp.mp4.concat':
  Duration: N/A, start: 0.000000, bitrate: 2634 kb/s
  Stream #0:0(eng): Video: vp9 (Profile 0) (vp09 / 0x39307076), yuv420p(tv, bt709), 2560x1280, 2518 kb/s, SAR 1:1 DAR 2:1, 29.97 fps, 29.97 tbr, 16k tbn, 16k tbc
    Metadata:
      handler_name    : VideoHandler
      vendor_id       : [0][0][0][0]
  Stream #0:1(eng): Audio: opus (Opus / 0x7375704F), 48000 Hz, stereo, fltp, 115 kb/s
    Metadata:
      handler_name    : SoundHandler
      vendor_id       : [0][0][0][0]
  Stream #0:2(eng): Subtitle: mov_text (tx3g / 0x67337874), 0 kb/s
    Metadata:
      handler_name    : SubtitleHandler
Multiple -c, -codec, -acodec, -vcodec, -scodec or -dcodec options specified for stream 2, only the last option '-c:s mov_text' will be used.
[mp4 @ 0x7f338f99b2c0] track 1: codec frame size is not set
Output #0, mp4, to 'file:/downloads/Marques Brownlee/Samsung Z Flip 3 Review - The First Big Step!.temp.mp4':
  Metadata:
    encoder         : Lavf58.76.100
  Stream #0:0(eng): Video: vp9 (Profile 0) (vp09 / 0x39307076), yuv420p(tv, bt709), 2560x1280 [SAR 1:1 DAR 2:1], q=2-31, 2518 kb/s, 29.97 fps, 29.97 tbr, 16k tbn, 16k tbc
    Metadata:
      handler_name    : VideoHandler
      vendor_id       : [0][0][0][0]
  Stream #0:1(eng): Audio: opus (Opus / 0x7375704F), 48000 Hz, stereo, fltp, 115 kb/s
    Metadata:
      handler_name    : SoundHandler
      vendor_id       : [0][0][0][0]
  Stream #0:2(eng): Subtitle: mov_text (tx3g / 0x67337874)
    Metadata:
      handler_name    : SubtitleHandler
      encoder         : Lavc58.134.100 mov_text
Stream mapping:
  Stream #0:0 -> #0:0 (copy)
  Stream #0:1 -> #0:1 (copy)
  Stream #0:2 -> #0:2 (mov_text (native) -> mov_text (native))
[mp4 @ 0x7f338f99b2c0] Non-monotonous DTS in output stream 0:1; previous: 5065968, current: 5064942; changing to 5065969. This may result in incorrect timestamps in the output file.
[concat @ 0x7f3390f40640] DTS 1688602 < 1688624 out of order
[mp4 @ 0x7f338f99b2c0] Application provided invalid, non monotonically increasing dts to muxer in stream 0: 1688624 >= 1688602
av_interleaved_write_frame(): Invalid argument
[mp4 @ 0x7f338f99b2c0] Starting second pass: moving the moov atom to the beginning of the file
frame= 3165 fps=2735 q=-1.0 Lsize=   34806kB time=00:01:45.54 bitrate=2701.6kbits/s speed=91.2x
video:33270kB audio:1524kB subtitle:2kB other streams:0kB global headers:0kB muxing overhead: 0.027754%
Conversion failed!
  File "/usr/lib/python3.9/runpy.py", line 197, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "/usr/lib/python3.9/runpy.py", line 87, in _run_code
    exec(code, run_globals)
  File "/usr/bin/yt-dlp/__main__.py", line 19, in <module>
    yt_dlp.main()
  File "/usr/bin/yt-dlp/yt_dlp/__init__.py", line 776, in main
    _real_main(argv)
  File "/usr/bin/yt-dlp/yt_dlp/__init__.py", line 766, in _real_main
    retcode = ydl.download(all_urls)
  File "/usr/bin/yt-dlp/yt_dlp/YoutubeDL.py", line 2894, in download
    res = self.extract_info(
  File "/usr/bin/yt-dlp/yt_dlp/YoutubeDL.py", line 1207, in extract_info
    return self.__extract_info(url, self.get_info_extractor(ie_key), download, extra_info, process)
  File "/usr/bin/yt-dlp/yt_dlp/YoutubeDL.py", line 1214, in wrapper
    return func(self, *args, **kwargs)
  File "/usr/bin/yt-dlp/yt_dlp/YoutubeDL.py", line 1252, in __extract_info
    return self.process_ie_result(ie_result, download, extra_info)
  File "/usr/bin/yt-dlp/yt_dlp/YoutubeDL.py", line 1298, in process_ie_result
    ie_result = self.process_video_result(ie_result, download=download)
  File "/usr/bin/yt-dlp/yt_dlp/YoutubeDL.py", line 2320, in process_video_result
    self.process_info(new_info)
  File "/usr/bin/yt-dlp/yt_dlp/YoutubeDL.py", line 2864, in process_info
    info_dict = self.post_process(dl_filename, info_dict, files_to_move)
  File "/usr/bin/yt-dlp/yt_dlp/YoutubeDL.py", line 3015, in post_process
    info = self.run_pp(pp, info)
  File "/usr/bin/yt-dlp/yt_dlp/YoutubeDL.py", line 2964, in run_pp
    files_to_delete, infodict = pp.run(infodict)
  File "/usr/bin/yt-dlp/yt_dlp/postprocessor/common.py", line 83, in wrapper
    return func(self, info)
  File "/usr/bin/yt-dlp/yt_dlp/postprocessor/modify_chapters.py", line 64, in run
    in_out_files = [remove_chapters(info['filepath'], False)]
  File "/usr/bin/yt-dlp/yt_dlp/postprocessor/modify_chapters.py", line 62, in remove_chapters
    return file, self.remove_chapters(file, cuts, concat_opts, self._force_keyframes and not is_sub)
  File "/usr/bin/yt-dlp/yt_dlp/postprocessor/modify_chapters.py", line 316, in remove_chapters
    self.concat_files([in_file] * len(concat_opts), out_file, concat_opts)
  File "/usr/bin/yt-dlp/yt_dlp/postprocessor/ffmpeg.py", line 332, in concat_files
    self.real_run_ffmpeg(
  File "/usr/bin/yt-dlp/yt_dlp/postprocessor/ffmpeg.py", line 274, in real_run_ffmpeg
    self.report_error(stderr)
  File "/usr/bin/yt-dlp/yt_dlp/postprocessor/common.py", line 56, in report_error
    return self._downloader.report_error(text, *args, **kwargs)
  File "/usr/bin/yt-dlp/yt_dlp/YoutubeDL.py", line 818, in report_error
    self.trouble(error_message, tb)
  File "/usr/bin/yt-dlp/yt_dlp/YoutubeDL.py", line 774, in trouble
    tb_data = traceback.format_list(traceback.extract_stack())

ERROR: Postprocessing: Conversion failed!
Traceback (most recent call last):
  File "/usr/bin/yt-dlp/yt_dlp/YoutubeDL.py", line 2864, in process_info
    info_dict = self.post_process(dl_filename, info_dict, files_to_move)
  File "/usr/bin/yt-dlp/yt_dlp/YoutubeDL.py", line 3015, in post_process
    info = self.run_pp(pp, info)
  File "/usr/bin/yt-dlp/yt_dlp/YoutubeDL.py", line 2964, in run_pp
    files_to_delete, infodict = pp.run(infodict)
  File "/usr/bin/yt-dlp/yt_dlp/postprocessor/common.py", line 83, in wrapper
    return func(self, info)
  File "/usr/bin/yt-dlp/yt_dlp/postprocessor/modify_chapters.py", line 64, in run
    in_out_files = [remove_chapters(info['filepath'], False)]
  File "/usr/bin/yt-dlp/yt_dlp/postprocessor/modify_chapters.py", line 62, in remove_chapters
    return file, self.remove_chapters(file, cuts, concat_opts, self._force_keyframes and not is_sub)
  File "/usr/bin/yt-dlp/yt_dlp/postprocessor/modify_chapters.py", line 316, in remove_chapters
    self.concat_files([in_file] * len(concat_opts), out_file, concat_opts)
  File "/usr/bin/yt-dlp/yt_dlp/postprocessor/ffmpeg.py", line 332, in concat_files
    self.real_run_ffmpeg(
  File "/usr/bin/yt-dlp/yt_dlp/postprocessor/ffmpeg.py", line 275, in real_run_ffmpeg
    raise FFmpegPostProcessorError(stderr.split('\n')[-1])
yt_dlp.postprocessor.ffmpeg.FFmpegPostProcessorError: Conversion failed!

Description

Hello there! 😃

I am trying out the new SponsorBlock implementation and are running into issues, marking chapters works for me but when adding --sponsorblock-remove sponsor or --sponsorblock-remove all this ffmpeg conversion error occurs.

Thank you for your help!

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Reactions:3
  • Comments:22 (11 by maintainers)

github_iconTop GitHub Comments

21reactions
pukkandancommented, Jan 16, 2022

This is an ffmpeg issue. See https://github.com/ytdl-org/youtube-dl/issues/28042, https://github.com/yt-dlp/yt-dlp/pull/360#issuecomment-860061594

TLDR: FFmpeg doesnot handle merging (or in this case, cutting) some vp9+aac formats from youtube correctly. This issue exists in all ffmpeg versions above 3.0.1. The possible solutions right now are:

  1. Use a custom patched version of ffmpeg like https://github.com/yt-dlp/FFmpeg-Builds#ffmpeg-static-auto-builds
  2. Download different formats
  3. Use ffmpeg 3.0.1
  4. --force-keyframes also work for sponsorblock, but is probably the worst of these fixes
Read more comments on GitHub >

github_iconTop Results From Across the Web

[Bug] Postprocessing Conversion Failed #1228 - yt-dlp/yt-dlp
Checklist I'm reporting a bug unrelated to a specific site I've verified that I'm running yt-dlp version 2021.10.10 I've checked that all ...
Read more >
Error at the end of post-processing with Youtube DLG - Reddit
r/youtubedl - Error at the end of post-processing with Youtube DLG. Hello everyone, ... FFmpegPostProcessorError: Conversion failed!
Read more >
How to fix the download failure with yt-dlp command for some ...
Conversion failed ! ERROR: ffmpeg exited with code 1. Any suggestion that how I can add some parameter to keep the download continue?...
Read more >
Heroku FFMPEG Postprocessing error with yt-dlp ...
I am building a discord music bot that uses FFMPEG to download and play the music. yt-dlp seems to not be able to...
Read more >
[FFmpeg-user] Issue affecting ffmpeg and youtube-dl
There apparently is an issue where ffmpeg will error out on trying to join VP9 HFR video in ... FFmpegPostProcessorError: Conversion failed!
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found