外部下载器选项在 youtube-dl 中无法正常工作

external-downloader option not working as expected in youtube-dl

我正尝试使用 youtube-dl 从 youtube 下载特定时间戳,如前所述 as mentioned here in the comments

youtube-dl -v "https://www.youtube.com/watch?v=1I-3vJSC-Vo" -x -k --external-downloader ffmpeg --external-downloader-args "-ss 0:30 -to 0:35"

我收到以下错误:

[youtube] 1I-3vJSC-Vo: Downloading webpage
[download] Destination: ONE MINUTE OF PURE SATISFACTION _ Compilation 1-1I-3vJSC-Vo.f398.mp4
ffmpeg version 3.4.8-0ubuntu0.2 Copyright (c) 2000-2020 the FFmpeg developers
  built with gcc 7 (Ubuntu 7.5.0-3ubuntu1~18.04)
  configuration: --prefix=/usr --extra-version=0ubuntu0.2 --toolchain=hardened --libdir=/usr/lib/x86_64-linux-gnu --incdir=/usr/incl
ude/x86_64-linux-gnu --enable-gpl --disable-stripping --enable-avresample --enable-avisynth --enable-gnutls --enable-ladspa --enable
-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libcdio --enable-libflite --enable-libfontconfig --enable-libf
reetype --enable-libfribidi --enable-libgme --enable-libgsm --enable-libmp3lame --enable-libmysofa --enable-libopenjpeg --enable-lib
openmpt --enable-libopus --enable-libpulse --enable-librubberband --enable-librsvg --enable-libshine --enable-libsnappy --enable-lib
soxr --enable-libspeex --enable-libssh --enable-libtheora --enable-libtwolame --enable-libvorbis --enable-libvpx --enable-libwavpack
 --enable-libwebp --enable-libx265 --enable-libxml2 --enable-libxvid --enable-libzmq --enable-libzvbi --enable-omx --enable-openal -
-enable-opengl --enable-sdl2 --enable-libdc1394 --enable-libdrm --enable-libiec61883 --enable-chromaprint --enable-frei0r --enable-l
ibopencv --enable-libx264 --enable-shared
  WARNING: library configuration mismatch
  avcodec     configuration: --prefix=/usr --extra-version=0ubuntu0.2 --toolchain=hardened --libdir=/usr/lib/x86_64-linux-gnu --incd
ir=/usr/include/x86_64-linux-gnu --enable-gpl --disable-stripping --enable-avresample --enable-avisynth --enable-gnutls --enable-lad
spa --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libcdio --enable-libflite --enable-libfontconfig -
-enable-libfreetype --enable-libfribidi --enable-libgme --enable-libgsm --enable-libmp3lame --enable-libmysofa --enable-libopenjpeg
--enable-libopenmpt --enable-libopus --enable-libpulse --enable-librubberband --enable-librsvg --enable-libshine --enable-libsnappy
--enable-libsoxr --enable-libspeex --enable-libssh --enable-libtheora --enable-libtwolame --enable-libvorbis --enable-libvpx --enabl
e-libwavpack --enable-libwebp --enable-libx265 --enable-libxml2 --enable-libxvid --enable-libzmq --enable-libzvbi --enable-omx --ena
ble-openal --enable-opengl --enable-sdl2 --enable-libdc1394 --enable-libdrm --enable-libiec61883 --enable-chromaprint --enable-frei0
r --enable-libopencv --enable-libx264 --enable-shared --enable-version3 --disable-doc --disable-programs --enable-libopencore_amrnb
--enable-libopencore_amrwb --enable-libtesseract --enable-libvo_amrwbenc
  libavutil      55. 78.100 / 55. 78.100
  libavcodec     57.107.100 / 57.107.100
  libavformat    57. 83.100 / 57. 83.100
  libavdevice    57. 10.100 / 57. 10.100
  libavfilter     6.107.100 /  6.107.100
  libavresample   3.  7.  0 /  3.  7.  0
  libswscale      4.  8.100 /  4.  8.100
  libswresample   2.  9.100 /  2.  9.100
  libpostproc    54.  7.100 / 54.  7.100
Option to (record or transcode stop time) cannot be applied to input url https://r7---sn-gwpa-civk.googlevideo.com/videoplayback?exp
ire=1617150322&ei=Em1jYPnzG7qr3LUP6eGr2A0&ip=2409%3A4043%3A609%3A4b92%3Ad9f7%3Ad14%3A44f9%3A8525&id=o-AALoNXBA9D9WAuCZn-2a9-JjLoqCOC
_11Lo7_9LdU7g0&itag=398&aitags=133%2C134%2C135%2C136%2C160%2C242%2C243%2C244%2C247%2C278%2C394%2C395%2C396%2C397%2C398&source=youtub
e&requiressl=yes&mh=05&mm=31%2C29&mn=sn-gwpa-civk%2Csn-gwpa-cvhd&ms=au%2Crdu&mv=m&mvi=7&pcm2cms=yes&pl=38&initcwndbps=148750&vprv=1&
mime=video%2Fmp4&ns=_3yx5zxNR1CYgHJamv8F-s4F&gir=yes&clen=4733883&dur=59.920&lmt=1578997687942906&mt=1617128452&fvip=7&keepalive=yes
&fexp=24001373%2C24007246&beids=9466588&c=WEB&txp=5431432&n=HoSSxcQKm_nNAUWgVTbz2&sparams=expire%2Cei%2Cip%2Cid%2Caitags%2Csource%2C
requiressl%2Cvprv%2Cmime%2Cns%2Cgir%2Cclen%2Cdur%2Clmt&sig=AOq0QJ8wRQIhAN-MjT3t_kpgwkOrBiw8f-0q5iDINPxu4bjfgZS66nNGAiBOLta-kt_AuaqGH
D-hJiElj9oNALl35IsBseYOR5AU4A%3D%3D&lsparams=mh%2Cmm%2Cmn%2Cms%2Cmv%2Cmvi%2Cpcm2cms%2Cpl%2Cinitcwndbps&lsig=AG3C_xAwRAIgIf334bMxslsq
Lxpnn2BATGGV6GWoWoJQQuMMgQL-NaMCICojD-uZ1VkyxIOQrfOwlLAEJ-gCe1skejtRBk-oHejU -- you are trying to apply an input option to an output
 file or vice versa. Move this option before the file it belongs to.
Error parsing options for input file https://r7---sn-gwpa-civk.googlevideo.com/videoplayback?expire=1617150322&ei=Em1jYPnzG7qr3LUP6e
Gr2A0&ip=2409%3A4043%3A609%3A4b92%3Ad9f7%3Ad14%3A44f9%3A8525&id=o-AALoNXBA9D9WAuCZn-2a9-JjLoqCOC_11Lo7_9LdU7g0&itag=398&aitags=133%2
C134%2C135%2C136%2C160%2C242%2C243%2C244%2C247%2C278%2C394%2C395%2C396%2C397%2C398&source=youtube&requiressl=yes&mh=05&mm=31%2C29&mn
=sn-gwpa-civk%2Csn-gwpa-cvhd&ms=au%2Crdu&mv=m&mvi=7&pcm2cms=yes&pl=38&initcwndbps=148750&vprv=1&mime=video%2Fmp4&ns=_3yx5zxNR1CYgHJa
mv8F-s4F&gir=yes&clen=4733883&dur=59.920&lmt=1578997687942906&mt=1617128452&fvip=7&keepalive=yes&fexp=24001373%2C24007246&beids=9466
588&c=WEB&txp=5431432&n=HoSSxcQKm_nNAUWgVTbz2&sparams=expire%2Cei%2Cip%2Cid%2Caitags%2Csource%2Crequiressl%2Cvprv%2Cmime%2Cns%2Cgir%
2Cclen%2Cdur%2Clmt&sig=AOq0QJ8wRQIhAN-MjT3t_kpgwkOrBiw8f-0q5iDINPxu4bjfgZS66nNGAiBOLta-kt_AuaqGHD-hJiElj9oNALl35IsBseYOR5AU4A%3D%3D&
lsparams=mh%2Cmm%2Cmn%2Cms%2Cmv%2Cmvi%2Cpcm2cms%2Cpl%2Cinitcwndbps&lsig=AG3C_xAwRAIgIf334bMxslsqLxpnn2BATGGV6GWoWoJQQuMMgQL-NaMCICoj
D-uZ1VkyxIOQrfOwlLAEJ-gCe1skejtRBk-oHejU.
Error opening input files: Invalid argument


ERROR: ffmpeg exited with code 1

为什么我使用的格式与 link 中提到的相同?

你的ffmpeg版本太旧了。您至少需要 v4.0.