G
gregpinero
Let's say I have this Python file called loop.py:
import sys
print 'hi'
sys.stdout.flush()
while 1:
pass
And I want to call it from another Python process and read the value
'hi'. How would I do it?
So far I have tried this:
But it just hangs at read()
proc.communicate() also just hangs. What am I doing wrong? Please
advise.
Thanks,
Greg
import sys
print 'hi'
sys.stdout.flush()
while 1:
pass
And I want to call it from another Python process and read the value
'hi'. How would I do it?
So far I have tried this:
But it just hangs at read()
proc.communicate() also just hangs. What am I doing wrong? Please
advise.
Thanks,
Greg