the_platinum_searcher icon indicating copy to clipboard operation
the_platinum_searcher copied to clipboard

There is something wrong with pt using python.

Open Yggdroot opened this issue 7 years ago • 0 comments

import subprocess
aaa = subprocess.check_output('pt -g"" .', shell=True)
bbb = subprocess.Popen('pt -g "" .',shell=True,stdout=subprocess.PIPE).stdout.read()
ccc = subprocess.Popen('pt -g "" .',shell=True,stdin=subprocess.PIPE,stdout=subprocess.PIPE).stdout.read()

print aaa
print bbb
print ccc

The result of aaa and bbb is good as expected, but ccc is empty. I think there is something wrong with pt about pipe.

On windows 10.

Yggdroot avatar Jun 02 '17 13:06 Yggdroot