From b75b6b1aa63f719410b6201c1302ad4f6c610fc4 Mon Sep 17 00:00:00 2001 From: Khoa Vo Date: Thu, 1 Jan 2026 16:07:10 +0700 Subject: [PATCH] Fix NAS playback: Force IPv4 and use stable clients for yt-dlp --- backend/api/routes.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/backend/api/routes.py b/backend/api/routes.py index dc1c811..fcff815 100644 --- a/backend/api/routes.py +++ b/backend/api/routes.py @@ -626,6 +626,8 @@ async def stream_audio(id: str): 'geo_bypass': True, # Bypass geo restrictions 'socket_timeout': 30, # Timeout for sockets 'retries': 3, # Retry on transient errors + 'force_ipv4': True, # Force IPv4 (Fixes NAS/Docker IPv6 issues) + 'extractor_args': {'youtube': {'player_client': ['ios', 'android', 'web']}}, # Use stable clients } # Extract direct URL