X-Git-Url: http://git.onelab.eu/?p=sface.git;a=blobdiff_plain;f=sface%2Fsfiprocess.py;h=05199c9ec1c62fb4d0b92a5b7cb89ba40bd62dd5;hp=27c5b7c2bba25f773e86f8dea3a7bf32d0e69d92;hb=e5eb62ef022ab41be7f2eb0b3ac8723874d1601a;hpb=c8a31d5f8c07dd3ebb6d622752fab424a72c0c2f diff --git a/sface/sfiprocess.py b/sface/sfiprocess.py index 27c5b7c..05199c9 100644 --- a/sface/sfiprocess.py +++ b/sface/sfiprocess.py @@ -25,6 +25,9 @@ class SfiProcess(QObject): self.args << QString(arg) self.exe = find_executable("sfi.py") + if not self.exe: + print "FATAL.. Could not locate binary sfi.py - not much we can do without that" + self.process = QProcess() self.connect(self.process, SIGNAL("finished(int, QProcess::ExitStatus)"), @@ -43,7 +46,7 @@ class SfiProcess(QObject): except: pass args = ["-u", config.getUser(), "-a", config.getAuthority(), - "-r", config.registry(), "-s", mgr, "resources", + "-r", config.getRegistry(), "-s", mgr, "resources", "-o", filename, slice] self.__init_command(args) @@ -51,14 +54,14 @@ class SfiProcess(QObject): return filename def getRSpecFromSM(self): - return self.__getRSpec(config.slicemgr()) + return self.__getRSpec(config.getSlicemgr()) def getRSpecFromAM(self): - return self.__getRSpec(config.aggmgr()) + return self.__getRSpec(config.getAggmgr()) def getRecord(self, hrn): args = ["-u", config.getUser(), "-a", config.getAuthority(), - "-r", config.registry(), "-s", config.slicemgr(), "show", hrn] + "-r", config.getRegistry(), "-s", config.getSlicemgr(), "show", hrn] self.__init_command(args) self.start() @@ -71,12 +74,12 @@ class SfiProcess(QObject): return self.process.readAll() def trace_command (self): - if config.SFACE_VERBOSE: + if config.verbose: self._trace=time.time() command = "%s %s" % (self.exe, self.args.join(" ")) print time.strftime('%M:%S'),'Invoking',command def trace_end (self): - if config.SFACE_VERBOSE: + if config.verbose: command = "%s %s" % (self.exe, self.args.join(" ")) print time.strftime('%M:%S'),"[%.3f s]"%(time.time()-self._trace),command,'Done'