From 3a2fd8e6c8afe2a2ddfecff54724d0993bdd836d Mon Sep 17 00:00:00 2001 From: mdipierro Date: Mon, 23 Jul 2012 17:23:27 -0500 Subject: [PATCH] another attempt to fix winservice issue --- VERSION | 2 +- gluon/winservice.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/VERSION b/VERSION index f750a6e2..f964822b 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -Version 2.00.0 (2012-07-23 16:19:51) dev +Version 2.00.0 (2012-07-23 17:23:22) dev diff --git a/gluon/winservice.py b/gluon/winservice.py index d4355111..4a818a80 100644 --- a/gluon/winservice.py +++ b/gluon/winservice.py @@ -92,6 +92,8 @@ class Web2pyService(Service): _winreg.CloseKey(h) dir = os.path.dirname(cls) os.chdir(dir) + global_settings.gluon_parent = dir + custom_import_install(dir) return True except: self.log("Can't change to web2py working path; server is stopped") @@ -151,8 +153,6 @@ def web2py_windows_service_handler(argv=None, opt_file='options'): path = os.path.dirname(__file__) web2py_path = iup(path) os.chdir(web2py_path) - global_settings.gluon_parent = web2py_path - custom_import_install(web2py_path) classstring = os.path.normpath( os.path.join(web2py_path,'gluon.winservice.Web2pyService')) if opt_file: