Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Re: subprocess.Popen() and a .msi installer

22 views
Skip to first unread message

Benjamin Kaplan

unread,
Dec 17, 2010, 6:27:36 PM12/17/10
to pytho...@python.org
On Fri, Dec 17, 2010 at 5:57 PM, Sebastian Alonso
<alon.se...@gmail.com> wrote:
> Hey everyone, I'm working on a script which uses subprocess to launch a
> bunch of installers, but I'm getting problems with .msi installers although
> .exe ones work fine. The output I get is this:
>
>>>> import subprocess
>>>> p = subprocess.Popen('python.msi')
> Traceback (most recent call last):
> File "<pyshell#1>", line 1, in <module>
> p = subprocess.Popen('python.msi')
> File "C:\Python25\lib\subprocess.py", line 593, in __init__
> errread, errwrite)
> File "C:\Python25\lib\subprocess.py", line 793, in _execute_child
> startupinfo)
> WindowsError: [Error 8] %1 no es una aplicación Win32 válida
>>>>
>
> Has this ever happen to any of you? The idea is to get this running, make it
> an exe (with py2exe) and use it whenever I need to install my whole
> development environment in the right order.
>
> Thanks in advance to all of you.
>
>
> Alonso Sebastian.
>

msi files are not executables. You need to use msiexec to run them.

Nobody

unread,
Dec 18, 2010, 10:04:33 AM12/18/10
to
On Fri, Dec 17, 2010 at 17:57, Sebastian Alonso wrote:

> Hey everyone, I'm working on a script which uses subprocess to launch a
> bunch of installers, but I'm getting problems with .msi installers
> although .exe ones work fine. The output I get is this:
>
>>>> import subprocess
>>>> p = subprocess.Popen('python.msi')

You need to add shell=True to "execute" anything which isn't a binary
executable (EXE).

0 new messages