Changeset 10139 for ossiedev/trunk/tools/wavedash/src/WavedashUtils.py
- Timestamp:
- 07/14/10 15:03:51 (3 years ago)
- Files:
-
- 1 modified
Legend:
- Unmodified
- Added
- Removed
-
ossiedev/trunk/tools/wavedash/src/WavedashUtils.py
r10108 r10139 203 203 if self.obj is None: 204 204 print "init_CORBA(): FATAL Error: Could not resolve initial references" 205 206 205 showMessage('Could not resolve initial references' , FATAL, self.enableGUI) 207 206 return … … 211 210 #print "init_CORBA(): FATAL Error: Failed to get naming context" 212 211 #showMessage('Could not initialize CORBA. Failed to get naming context \n The application will now exit.', FATAL) 212 213 213 newNS = False 214 214 while not newNS: 215 215 ts = "Failed to narrow the root naming context.\n" 216 216 ts += "Are the Naming Service and nodeBooter running on "+self.__namingservice+"?" 217 217 218 showMessage(ts, NON_FATAL, self.enableGUI) 218 219 nsDialog = NamingserviceDialog(self) … … 220 221 newNS = True 221 222 elif nsDialog.GetReturnCode() == -2: 222 sys.exit(-1) 223 sys.exit(-1) 224 223 225 return 224 226 … … 266 268 except(CORBA.TRANSIENT), val: 267 269 #print "In getApplications():", str(val) 268 showMessage("Exception! " + str(val) + "\n Could not get applications from Domain Manager \n Exiting now!!!" , FATAL )270 showMessage("Exception! " + str(val) + "\n Could not get applications from Domain Manager \n Exiting now!!!" , FATAL, self.enableGUI) 269 271 sys.exit(-1) 270 272 members = dom_context.list(100) … … 303 305 devMgrSeq = self.domMgr._get_deviceManagers() 304 306 except(CORBA.COMM_FAILURE, CORBA.TRANSIENT), val: 305 showMessage("Exception: " + str(val) + "\n - Could not get device managers!" , NON_FATAL )307 showMessage("Exception: " + str(val) + "\n - Could not get device managers!" , NON_FATAL, self.enableGUI) 306 308 return 307 309 … … 330 332 if len(assigndeviceidNodeList) == 0: 331 333 ts = "Could not find \"assigndeviceid\" tag\nAborting install" 332 showMessage(ts, NON_FATAL )334 showMessage(ts, NON_FATAL, self.enableGUI) 333 335 #errorMsg(self, ts) 334 336 return … … 341 343 ts = "Could not find the required device: " + str(assigndeviceid) 342 344 ts += "\nAborting install" 343 showMessage(ts, NON_FATAL )345 showMessage(ts, NON_FATAL, self.enableGUI) 344 346 #errorMsg(self, ts) 345 347 return … … 357 359 358 360 if app_factory_num == -1: 359 showMessage ("Application factory not found", NON_FATAL )361 showMessage ("Application factory not found", NON_FATAL, self.enableGUI) 360 362 361 363 … … 365 367 app = _applicationFactories[app_factory_num].create(_applicationFactories[app_factory_num]._get_name(),_appFacProps,_devSeq) 366 368 except: 367 showMessage("Unable to create application\nMake sure that all appropriate nodes are installed", NON_FATAL )369 showMessage("Unable to create application\nMake sure that all appropriate nodes are installed", NON_FATAL, self.enableGUI) 368 370 return(None) 369 371 … … 382 384 appRef = self.getAppRef(wformName) 383 385 if appRef is None: 384 showMessage("Error: Failed to get application reference for " + wformName, NON_FATAL )386 showMessage("Error: Failed to get application reference for " + wformName, NON_FATAL, self.enableGUI) 385 387 return False 386 388 appRef.releaseObject() 387 389 except(CORBA.COMM_FAILURE, CORBA.INV_OBJREF), val: 388 showMessage("Exception: " + str(val) + "\n - Could not uninstall " + wformName, NON_FATAL )390 showMessage("Exception: " + str(val) + "\n - Could not uninstall " + wformName, NON_FATAL, self.enableGUI) 389 391 return False 390 392 return True … … 420 422 try: 421 423 if dom_context is None: 422 showMessage('Could not reference for DomainName1', NON_FATAL )424 showMessage('Could not reference for DomainName1', NON_FATAL, self.enableGUI) 423 425 return 424 426 appSeq = self.domMgr._get_applications() … … 461 463 prpRsrcRef = self.rootContext.resolve(prp) 462 464 if prpRsrcRef is None: 463 showMessage(("Unable to find rootContext for %s/%s" % (wformName,compName)), NON_FATAL )465 showMessage(("Unable to find rootContext for %s/%s" % (wformName,compName)), NON_FATAL, self.enableGUI) 464 466 return None 465 467 … … 468 470 469 471 if prpSetHandle is None: 470 showMessage(("Unable to get PropertySet reference for %s/%s" % (wformName, compName)), NON_FATAL )472 showMessage(("Unable to get PropertySet reference for %s/%s" % (wformName, compName)), NON_FATAL, self.enableGUI) 471 473 472 474 if len(prpList) == 0: … … 475 477 except: 476 478 errorMsg = sys.exc_info()[1] 477 showMessage(str(errorMsg), NON_FATAL )479 showMessage(str(errorMsg), NON_FATAL, self.enableGUI) 478 480 return None 479 481 … … 489 491 prpRsrcRef = self.rootContext.resolve(prpRef) 490 492 if prpRsrcRef is None: 491 showMessage(("Unable to find rootContext for %s/%s" % (wformName,compName)), NON_FATAL )493 showMessage(("Unable to find rootContext for %s/%s" % (wformName,compName)), NON_FATAL, self.enableGUI) 492 494 return False 493 495 … … 495 497 prpSetHandle = prpRsrcRef._narrow(CF.PropertySet) 496 498 if prpSetHandle is None: 497 showMessage(("Unable to get PropertySet reference for %s/%s" % (wformName, compName)), NON_FATAL )499 showMessage(("Unable to get PropertySet reference for %s/%s" % (wformName, compName)), NON_FATAL, self.enableGUI) 498 500 return False 499 501 prpSetHandle.configure(prpList) … … 502 504 except: 503 505 errorMsg = str(sys.exc_info()[1]) 504 showMessage("Exception! " + errorMsg + "\n Connection to Domain Manager Failed", NON_FATAL )506 showMessage("Exception! " + errorMsg + "\n Connection to Domain Manager Failed", NON_FATAL, self.enableGUI) 505 507 return False 506 508