Could not find ffmpeg, skipping conversion; but ffmpeg installed correctly
See original GitHub issue- Using latest version as provided on the master branch
- Searched for similar issues including closed ones Similar issue #70, however on that one the ffmpeg was actually recognised
What is the purpose of your issue?
- Bug
- Feature Request
- Question
- Other
Description
The program can’t convert m4a to mp3 because it says ffmpeg can’t be found. However, I did put the file into C:/Windows/System32 and I can use it from powershell. I tried writing out the full ffmpeg command (from debug log) to my powershell and it ran successfully converting the song.
Log
(cut out most relevant part, can provide full log if needed) (the second warning after the ffmpeg I added myself to see what the exception was)
DEBUG: Downloading from URL: https://r6---sn-8pgbpohxqp5-h5oz.googlevideo.com/videoplayback/id/bd7336038c00a6ca/itag/140/source/youtube/requiressl/yes/mm/31,29/pl/23/mn/sn-8pgbpohxqp5-h5oz,sn-aigl6n7z/initcwndbps/1861250/mv/m/ms/au,rdu/ei/6nBsW92nCsTvVt-2qPAN/ratebypass/yes/mime/audio%2Fmp4/otfp/1/gir/yes/clen/4591731/lmt/1520386557549759/dur/288.856/mt/1533833360/fvip/5/disable_polymer/true/ip/82.40.143.222/ipbits/0/expire/1533855050/sparams/ip,ipbits,expire,id,itag,source,requiressl,mm,pl,mn,initcwndbps,mv,ms,ei,ratebypass,mime,otfp,gir,clen,lmt,dur/signature/3439EEF687AC4838109628EB47252BED6426B19E.48A8DB4F8B0C25A2418F4A9B15FE3266809A474C/key/dg_yt0/ DEBUG: Saving to: /other/Cruk - Illusion.m4a 4,591,731 Bytes [100.00%] received. Rate: [11479 KB/s]. ETA: [0 secs] INFO: Converting Cruk - Illusion.m4a to mp3 DEBUG: [‘ffmpeg’, ‘-y’, ‘-i’, ‘/other/Cruk - Illusion.m4a’, ‘-codec:v’, ‘copy’, ‘-codec:a’, ‘libmp3lame’, ‘-ar’, ‘44100’, ‘-b:a’, ‘192k’, ‘-vn’, ‘/other/Cruk - Illusion.mp3’] WARNING: Could not find ffmpeg, skipping conversion WARNING: [WinError 2] The system cannot find the file specified INFO: Applying metadata DEBUG: Removing downloaded song from text file
Output from ffmpeg if i run command ‘ffmpeg’ in PS from spotdl root dir
ffmpeg version N-91589-ge0539f0349 Copyright © 2000-2018 the FFmpeg developers built with gcc 8.2.1 (GCC) 20180808 configuration: --enable-gpl --enable-version3 --enable-sdl2 --enable-bzlib --enable-fontconfig --enable-gnutls --enable-iconv --enable-libass --enable-libbluray --enable-libfreetype --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-libopus --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libtheora --enable-libtwolame --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxml2 --enable-libzimg --enable-lzma --enable-zlib --enable-gmp --enable-libvidstab --enable-libvorbis --enable-libvo-amrwbenc --enable-libmysofa --enable-libspeex --enable-libxvid --enable-libaom --enable-libmfx --enable-amf --enable-ffnvcodec --enable-cuvid --enable-d3d11va --enable-nvenc --enable-nvdec --enable-dxva2 --enable-avisynth libavutil 56. 18.102 / 56. 18.102 libavcodec 58. 22.101 / 58. 22.101 libavformat 58. 17.101 / 58. 17.101 libavdevice 58. 4.101 / 58. 4.101 libavfilter 7. 26.100 / 7. 26.100 libswscale 5. 2.100 / 5. 2.100 libswresample 3. 2.100 / 3. 2.100 libpostproc 55. 2.100 / 55. 2.100 Hyper fast Audio and Video encoder usage: ffmpeg [options] [[infile options] -i infile]… {[outfile options] outfile}…
Use -h to get full help or, even better, run ‘man ffmpeg’
Issue Analytics
- State:
- Created 5 years ago
- Comments:14 (1 by maintainers)
Yes, it’s strange. Maybe because python can find programs only that are present in PATH. I don’t really know but the good thing is that we found a solution.
@TheLifeGamingYT Yep, that will probably allow us to find FFmpeg when placed in System32. But, lots of other bad things could happen on the side. Using
shell=True
could completely change the way a command gets interpreted. So considering everything, IMO let’s avoidshell=True
.