I'm using HandbrakeCLI throw Python 2.7.1 on Windows, calling a process to execute it.
If I launch it using:
Code: Select all
import subprocess
retcode = subprocess.call(command_string)
I would like to use
Code: Select all
import subprocess
proc = subprocess.Popen(command_string,
stdin = subprocess.PIPE,
stdout = subprocess.PIPE,
stderr = subprocess.PIPE,)
When I launch it with this command, HandbrakeCLI is executed, works correctly, but it doesn't terminate... it stays to wait something, I don't know what.
If I check the TaskManager, during its work, the CPU of HandBrakeCLI.exe process is around 88%, correctly. When it has finished the encoding, the CPU is 0% and it doesn't do anything: the console is waiting that it terminates with a return code.
Do you know what is the problem?
Thank you!