Message160076
Works with 3.2.2:
Python 3.2.2+ (3.2:9ef20fbd340f, Oct 15 2011, 21:22:07)
[GCC 4.5.2] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> from subprocess import Popen, PIPE
>>> p=Popen(["/bin/sh"], stdin=PIPE, stderr=PIPE, stdout=PIPE)
>>> p.stdin.write(b"echo hello\n")
11
>>> p.stdout.readline()
b'hello\n'
Try calling p.stdin.flush() perhaps? |
|
Date |
User |
Action |
Args |
2012-05-06 11:55:40 | pitrou | set | recipients:
+ pitrou, gregory.p.smith, gangesmaster |
2012-05-06 11:55:40 | pitrou | set | messageid: <1336305340.06.0.94955415497.issue14737@psf.upfronthosting.co.za> |
2012-05-06 11:55:39 | pitrou | link | issue14737 messages |
2012-05-06 11:55:39 | pitrou | create | |
|