0

I am working on a Youtube to mp4 converter and I currently have two webm files(one containing the audio and one containing the video) and a .bat programm that converts them into a webm file with audio and video. I tryed to open the .bat file using this code:

import subprocess

subprocess.Popen(['C:/Users/mariu/Desktop/Youtube/a3.bat'])

But when I run the code I get this Error:

C:\Users\$$$\source\repos\Youtube Downloader\Youtube Downloader>ffmpeg -i 
C:/Users/$$$/Desktop/Youtube/1.webm -i C:/Users/$$$/Desktop/Youtube/2.webm -c copy 
C:/Users/$$$/Desktop/Youtube/output.webm
The command "ffmpeg" is either wrong or could not be found. (translated from german)

The .bat programm works when I simply execute it but it doesnt when using Python. I have also tryed to use os.system("path") but that also didn't work. Help would be appreciated.

1 Answers1

0

did you try to modify your .bat file to call ffmpeg using the full path?

Youtube Downloader>path\to\ffmpeg -i C:/Users/$$$/Desktop/Youtube/1.webm -i C:/Users/$$$/Desktop/Youtube/2.webm -c copy C:/Users/$$$/Desktop/Youtube/output.webm

sebo
  • 72
  • 7