My python script uses subprocess to call a linux utility that is very noisy. I want to store all of the output to a log file and show some of it to the user. I thought the
Dunno when this has been added to the subprocess module, but with Python 3 you should be fine with using proc.stdout.splitlines():
proc.stdout.splitlines()
for line in proc.stdout.splitlines(): print "stdout:", line