fork download
  1. import io
  2. import subprocess
  3.  
  4. with subprocess.Popen('ffmpeg -i file.webm -f mp4 -movflags empty_moov -', stdout=subprocess.PIPE) as proc:
  5. data = proc.stdout.read()
  6. fh = io.BytesIO(data)
Runtime error #stdin #stdout #stderr 0.16s 23856KB
stdin
Standard input is empty
stdout
Standard output is empty
stderr
Traceback (most recent call last):
  File "./prog.py", line 4, in <module>
  File "/usr/lib/python3.7/subprocess.py", line 775, in __init__
    restore_signals, start_new_session)
  File "/usr/lib/python3.7/subprocess.py", line 1522, in _execute_child
    raise child_exception_type(errno_num, err_msg, err_filename)
FileNotFoundError: [Errno 2] No such file or directory: 'ffmpeg -i file.webm -f mp4 -movflags empty_moov -': 'ffmpeg -i file.webm -f mp4 -movflags empty_moov -'