python and command shell on Windows

Eric_Dexter at msn.com Eric_Dexter at msn.com
Wed Dec 16 15:52:58 EST 2009


On Dec 16, 11:58 am, josu <josuj... at gmail.com> wrote:
> Hi
>
> I am trying to execute a windows command based on a shell by mean of
> python. I have proven subprocess
>
> test=subprocess.Popen
> (['shell_command'],shell=True,stdin=PIPE,stdout=PIPE)
>
> Initally, all seems ok, but, after seconds the python shell is frozen.
>
> Does someone know alternative ways valid for windows OS?
>
> Thanks in advance
>
> josu
os.startfile() works you will find the pipe commands are different on
unix and windows anyway.



More information about the Python-list mailing list