Page 1 of 1

returned non-zero exit status 1152

Published: February 7, 2017 - 5:12 PM
by gaelds
I am preparing a package for a Casio emulator, and I am stuck on error 1152 (= "Cannot start more than one instance of the specified program.").

For manual installation, I use the following command:
setup.exe /L"1036" /S /V" /QN ISX_INSTALLKEY=XXXX"

I don't know if I made a mistake with the quotation marks in the run? Or is that unrelated?

Code: Select all

# -*- coding: utf-8 -*-
# -----------------------------------------------------------------------
from setuphelpers import *
uninstallstring=''
uninstallkey=['{92A68E3F-F40B-472C-9F93-2729EBBF08DA}']

def install():
     print('Installation de Casio 35+ Manager+')
     run(r'casio\fx-Manager_PLUS\GRAPH_35+\setup.exe /L\"1036\" /S /V\" /QN ISX_INSTALLKEY=XXXX\"')

Error :
CalledProcessError: Command '('casio\\fx-Manager_PLUS\\GRAPH_35+\\setup.exe /L\\"1036\\" /S /V\\" /QN ISX_INSTALLKEY=XXXX\\"',)' returned non-zero exit status 1152

Re: returned non-zero exit status 1152

Published: May 4, 2017 - 2:43 PM
by gaelds
I finally found a solution for this Casio Graph 35+ package by using an MSI file that was extracted when the setup.exe was launched. Here is the working code (with a Casio education license):

Code: Select all

# -*- coding: utf-8 -*-
from setuphelpers import *
uninstallkey = []

def install():
    # if you want to modify the keys depending on environment (win32/win64... params..)
    global uninstallkey
    global uninstallstring
    softname = 'GRAPH 35+ Manager PLUS (School License)'
    versionsoft = control['version'].split('-',1)[0]
    check_installed_soft = installed_softwares(softname)
    if check_installed_soft:
             for uninstall in check_installed_soft:
                key=uninstall['key']
                if installed_softwares(uninstallkey=key):
                   if Version(uninstall['version']) < Version(versionsoft):
                         cmd = WAPT.uninstall_cmd(uninstall['key'])
                         run_notfatal(cmd)

    run_notfatal('GRAPH35PLUS.msi /L "1036" /qn ISX_INSTALLKEY=XXXXX')