diff --git a/badwitch.py b/badwitch.py index bd7f967..d0ab359 100755 --- a/badwitch.py +++ b/badwitch.py @@ -71,9 +71,14 @@ class Library: continue # Download the song ytdl_opts = { - 'audio-format': 'best', - 'x' - 'playlist-items': 1 + 'format': 'bestaudio', + 'postprocessors': [{ + 'key': 'FFmpegExtractAudio', + 'preferredcodec': 'opus', + 'preferredquality': '192' + }], + 'extract_audio': True, + 'playlist_items': 1, } with youtube_dl.YoutubeDL(ytdl_opts) as ydl: ydl.download([songcontent['source']])