Python Execute Shell Command And Get Stdout Is Not A Tty