# HG changeset patch # User Mads Kiilerich # Date 2017-08-12 17:30:33 # Node ID 24c9b2692ae4e0ff7214217962bdf6d1b567ef80 # Parent 240d54a3091eb23a99ae1909e5ec399c6a677573 install-iis: fix failure - replace paster ensure_file with explicit file writing ensure_file was a paster thing, not present in gearbox, and install-iis would thus fail. With this, install-iis has been tested to no longer crash. diff --git a/kallithea/lib/paster_commands/install_iis.py b/kallithea/lib/paster_commands/install_iis.py --- a/kallithea/lib/paster_commands/install_iis.py +++ b/kallithea/lib/paster_commands/install_iis.py @@ -75,10 +75,11 @@ class Command(BasePasterCommand): dispatchfile = os.path.join(os.getcwd(), 'dispatch.py') print 'Writing %s' % dispatchfile - self.ensure_file(dispatchfile, dispath_py_template % { + with file(dispatchfile, 'w') as f: + f.write(dispath_py_template % { 'inifile': config_file.replace('\\', '\\\\'), 'virtualdir': args.virtualdir, - }, False) + }) print ('Run \'python "%s" install\' with administrative privileges ' 'to generate the _dispatch.dll file and install it into the '