I am running a command with python3.4 subprocess. The command has 2 options, one standard and one interactive. The problem is that if I run it in the standard mode check_process returns immediately. I have also checked running it with subprocess.call
and then running the command in both modes takes longer.
In summary
subprocess.check_output([command]) //returns immediately
subprocess.check_output([command, "-i"]) // takes longer to run, returns output
subprocess.call([command]) // also takes longer to run
The command is running a go program, in which in case of the non interactive mode, I disable the output. Is it possible that because of this check_output returns immediately? From the documentation I understood that it's supposed to wait for the subprocess to return.
I have checked running the command from outside of the python script and in both interactive and standard mode it takes "a bit" to run.