ffmpeg-python
ffmpeg-python copied to clipboard
Request: Add option to suppress terminal creation for use with .pyw
When running ffmpeg.probe (and probably other commands) subprocess.Popen will attempt to open a new terminal when .pyw is used. The intent with .pyw is that the program will run without any terminals appearing, so this is undesirable.
The fix I found is simply including creationflags=subprocess.CREATE_NO_WINDOW in the Popen command like so:
p = subprocess.Popen(args, stdout=subprocess.PIPE, stderr=subprocess.PIPE, creationflags=subprocess.CREATE_NO_WINDOW)
Assuming there are use-cases where the terminal appearing is desirable, could a kwarg be added to turn them on/off, please?
+1