diff --git a/app/downloader.py b/app/downloader.py index 8b665ff..38a3a0b 100644 --- a/app/downloader.py +++ b/app/downloader.py @@ -43,8 +43,6 @@ async def extract_audio(url: str) -> Path: cmd = [ "yt-dlp", - "--no-warnings", - "--quiet", "--extract-audio", "--audio-format", "mp3", "--audio-quality", "128K", @@ -64,9 +62,14 @@ async def extract_audio(url: str) -> Path: stderr=asyncio.subprocess.PIPE, ) _, stderr = await proc.communicate() + stderr_text = stderr.decode().strip() + + if stderr_text: + import logging + logging.getLogger(__name__).warning("yt-dlp stderr: %s", stderr_text) if proc.returncode != 0: - raise RuntimeError(stderr.decode().strip() or "yt-dlp failed with no output") + raise RuntimeError(stderr_text or "yt-dlp failed with no output") if expected.exists(): return expected