views:

27

answers:

1

I am using a python script to execute an application to install a program. Using os.system('dir\\application.exe') works. However the installer has 2 installation parts and after completing the first one, it will hang there. The second one will only execute when I exit the python script. How can I get the whole installation process to complete without killing it in the script?

A: 

from what you provided it is not clear why the installer is hanging. I've ran installers here and it works fine. Which installer are you running? Is it public available?

As a sidenote, don't use os.system to run your application. It needlessy invokes the shell -- use subprocess module instead:

subprocess.call(['dir/application.exe'])
nosklo
BiX
@BiX: Yeah, that `subprocess.call` part was just a sidenote, not your issue's solution
nosklo