I am using python's subprocess
for executing scripts against a C code base. Concretely, I have a number of scripts that I run one by one against a single instantiation of a program. Here is what I want to do:
start process ABC
execute python scripts 01 against ABC and store output from ABC in file A
execute python scripts 02 against ABC and store output from ABC in file B
execute python scripts 03 against ABC and store output from ABC in file C
My current scheme with
myProcess = subprocess.Popen(PATH, BUFFSIZE, STDOUT= myFilePointer ...)
But this fails to yield return output from each execution of process ABC and only records output in case of script 01 and not the rest.
I have looked at official documentation and other resources but cannot find.