Marko Rauhamaa wrote:
> Anyway, Python has os.system() that does the quick and dirty thing you
> might be looking for.
Always invokes shell ==> overhead for .exe files
--
https://mail.python.org/mailman/listinfo/python-list
This discussion is getting really interesting and far beyond the actual topic :)
I want to add some additional thoughts on Popen:
Marko Rauhamaa wrote:
> Stefan Zimmermann:
>
> > And last but not least, Popen behavior on Windows makes it difficult
> > to write OS-independent
And last but not least, Popen behavior on Windows makes it difficult to write
OS-independent Python code which calls external commands that are not binary by
default:
2 examples:
1. I wrote a coffeetools package which wraps the CoffeeScript compiler in a
Python API. The 'coffee' command is a N
Nice to see that my topic gains that interest :)
And I see that I should have gone more into detail about what I'm actually
trying to point out.
Chris Angelico wrote:
> Hmm... hm... Ha! Found the difference. I had an explicit shebang on my
> script; yours just starts out with shell commands. That
Hi.
I don't like that subprocess.Popen(['command']) only works on Windows if there
is a command.exe in %PATH%. As a Windows user you would normally expect that
also command.bat and command.cmd can be run that way.
There are simple workarounds like Popen(..., shell=True) but that is a heavy
ove