I'm working downloading mp3 from youtube with youtube_dl. I installed ffprobe and ffmpeg through pip install ffprobe
and pip install ffmpeg
, but my code still returned the error in the title.
I tried adding the files here to PATH, as mentioned in a previous question, but it didn't work.
I have also tried using an anaconda environment, but it returned the same error as well.
Here's my code
from __future__ import unicode_literals
import youtube_dl
songs = ['https://www.youtube.com/watch?v=8qLL2Gx3I_k','https://www.youtube.com/watch?v=WNeLUngb-Xg', 'https://www.youtube.com/watch?v=saxxJZCr2-k', 'https://www.youtube.com/watch?v=pICAha0nsb0', 'https://www.youtube.com/watch?v=RCmKDK1TYmE']
ydl_opts = {'postprocessors': [{'key': 'FFmpegExtractAudio','preferredcodec': 'mp3','preferredquality': 0}]}
with youtube_dl.YoutubeDL(ydl_opts) as ydl:
ydl.download(songs)