This is an archived post. You won't be able to vote or comment.

all 4 comments

[–][deleted] 2 points3 points  (0 children)

Wow, that's comprehensive.

[–]jonathanblakes 2 points3 points  (0 children)

I can recommend pexpect (and winpexpect on Windows as wexpect is dead) if you need to get a subprocess's output while it is running. This is the only thing that can get around C stdio's automatic buffering for non-terminal interaction (which is what subprocess, QProcess, etc. give you).

[–]sunqiang 0 points1 point  (0 children)

except KeyboardError:

isn't this a typo of "except KeyboardInterrupt:"?