Skip to content

A feature-rich command-line audio/video downloader

Fix external downloader availability when using `--ffmpeg-location` (#12318)

Kenshin99779f77e04c76e3
diff --git a/yt_dlp/downloader/external.py b/yt_dlp/downloader/external.py
index 7f6b5b45cc..ee73ac043e 100644
--- a/yt_dlp/downloader/external.py
+++ b/yt_dlp/downloader/external.py
@@ -457,8 +457,6 @@ class FFmpegFD(ExternalFD):
@classmethod
def available(cls, path=None):
- # TODO: Fix path for ffmpeg
- # Fixme: This may be wrong when --ffmpeg-location is used
return FFmpegPostProcessor().available
def on_process_started(self, proc, stdin):
diff --git a/yt_dlp/postprocessor/ffmpeg.py b/yt_dlp/postprocessor/ffmpeg.py
index 8965806ae7..e59e9832bd 100644
--- a/yt_dlp/postprocessor/ffmpeg.py
+++ b/yt_dlp/postprocessor/ffmpeg.py
@@ -202,7 +202,7 @@ class FFmpegPostProcessor(PostProcessor):
@property
def available(self):
- return self.basename is not None
+ return bool(self._ffmpeg_location.get()) or self.basename is not None
@property
def executable(self):