Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ffprobe or avprobe not found. Please install one. #10029

Closed
gigalala opened this issue Jul 7, 2016 · 8 comments
Closed

ffprobe or avprobe not found. Please install one. #10029

gigalala opened this issue Jul 7, 2016 · 8 comments

Comments

@gigalala
Copy link

@gigalala gigalala commented Jul 7, 2016

Hi,
So i am trying to download a playlist using youtube-dl. But when i try to download my playlist the first video is downloaded and converted successfully, and on the second i get "ffprobe or avprobe not found. Please install one.".
Obviously i have both ffprobe and avprobe installed and can be used on my mac.

from __future__ import unicode_literals
import youtube_dl



ydl_opts = {
    'format': 'bestaudio/best',
    'postprocessors': [{
        'key': 'FFmpegExtractAudio',
        'preferredcodec': 'mp3',
        'preferredquality': '192'}]}


with youtube_dl.YoutubeDL(ydl_opts) as ydl:
    ydl.download(['https://www.youtube.com/playlist?list=PL_60Wu6jUZd8ppBT7t5lnRTjuChiJdz_R'])


Error:

Traceback (most recent call last):
  File "/Users/Avihai/Desktop/YoutubeDownloader/Test.py", line 15, in <module>
    ydl.download(['https://www.youtube.com/playlist?list=PL_60Wu6jUZd8ppBT7t5lnRTjuChiJdz_R'])
  File "/Library/Frameworks/Python.framework/Versions/3.4/lib/python3.4/site-packages/youtube_dl/YoutubeDL.py", line 1740, in download
    url, force_generic_extractor=self.params.get('force_generic_extractor', False))
  File "/Library/Frameworks/Python.framework/Versions/3.4/lib/python3.4/site-packages/youtube_dl/YoutubeDL.py", line 687, in extract_info
    return self.process_ie_result(ie_result, download, extra_info)
  File "/Library/Frameworks/Python.framework/Versions/3.4/lib/python3.4/site-packages/youtube_dl/YoutubeDL.py", line 848, in process_ie_result
    extra_info=extra)
  File "/Library/Frameworks/Python.framework/Versions/3.4/lib/python3.4/site-packages/youtube_dl/YoutubeDL.py", line 740, in process_ie_result
    extra_info=extra_info)
  File "/Library/Frameworks/Python.framework/Versions/3.4/lib/python3.4/site-packages/youtube_dl/YoutubeDL.py", line 687, in extract_info
    return self.process_ie_result(ie_result, download, extra_info)
  File "/Library/Frameworks/Python.framework/Versions/3.4/lib/python3.4/site-packages/youtube_dl/YoutubeDL.py", line 733, in process_ie_result
    return self.process_video_result(ie_result, download=download)
  File "/Library/Frameworks/Python.framework/Versions/3.4/lib/python3.4/site-packages/youtube_dl/YoutubeDL.py", line 1386, in process_video_result
    self.process_info(new_info)
  File "/Library/Frameworks/Python.framework/Versions/3.4/lib/python3.4/site-packages/youtube_dl/YoutubeDL.py", line 1722, in process_info
    self.post_process(filename, info_dict)
  File "/Library/Frameworks/Python.framework/Versions/3.4/lib/python3.4/site-packages/youtube_dl/YoutubeDL.py", line 1788, in post_process
    self.report_error(e.msg)
  File "/Library/Frameworks/Python.framework/Versions/3.4/lib/python3.4/site-packages/youtube_dl/YoutubeDL.py", line 550, in report_error
    self.trouble(error_message, tb)
  File "/Library/Frameworks/Python.framework/Versions/3.4/lib/python3.4/site-packages/youtube_dl/YoutubeDL.py", line 520, in trouble
    raise DownloadError(message, exc_info)
youtube_dl.utils.DownloadError: �[0;31mERROR:�[0m ffprobe or avprobe not found. Please install one.

Any ideas?
Thank you

@ivan
Copy link
Contributor

@ivan ivan commented Jul 7, 2016

You might have them installed, but are they in your PATH?

@gigalala
Copy link
Author

@gigalala gigalala commented Jul 7, 2016

Its a mac, so i am not sure what you mean by "PATH"

Thank you

@TRox1972
Copy link
Contributor

@TRox1972 TRox1972 commented Jul 7, 2016

@gigalala Print the output of echo $PATH and whereis ffmpeg

@gigalala
Copy link
Author

@gigalala gigalala commented Jul 8, 2016

echo $PATH output:
/Users/Avihai/Library/Ruby/Gems/1.8/bin:/Library/Frameworks/Python.framework/Versions/3.4/bin:/Library/Frameworks/Python.framework/Versions/3.3/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/sbin:/Users/Avihai/.yadr/bin:/Users/Avihai/.yadr/bin/yadr

whereis ffmpeg returns nothing, but i chekced and ffmepg is on "/usr/local/bin/" which is in PATH.
Can you think of a reason why the first video is downloaded and converted successfully, while i get the error on the second?

Thank you

@yan12125
Copy link
Collaborator

@yan12125 yan12125 commented Jul 8, 2016

Please add 'verbose': True to ydl_opts.

Also the path in Python may be different. Add print(os.getenv('PATH')) in your Python script.

@gigalala
Copy link
Author

@gigalala gigalala commented Jul 8, 2016

Hi,

@yan12125 you were right, print(os.getenv('PATH')) returns only/usr/bin:/bin:/usr/sbin:/sbin.
Why is that? and how i fix it?

Thank you

@yan12125
Copy link
Collaborator

@yan12125 yan12125 commented Jul 8, 2016

Why is that?

Depends. Most likely some startup scripts modifies PATH.

how i fix it?

Looks working: http://stackoverflow.com/a/1681244/3786245

@yan12125
Copy link
Collaborator

@yan12125 yan12125 commented Jul 11, 2016

I guess you have solved the problem. If not feel free to leave a comment here.

@yan12125 yan12125 closed this Jul 11, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
4 participants
You can’t perform that action at this time.