I have problem with Popen.communicate().
I have script which return string.
Then I have wrote second script which takes that variable.
v = "./myscript arg1 arg2"
com = subprocess.Popen(v, shell=True).communicate()
print com
com returns (None, None). The point is that I can print inside first script the results, shell print result as well. I can't just assign that print to variable.
Of course first script returns value, not print it.
From the docs:
Hence, create the
Popen
object with: