311 Bootstrap the application with minimal use of Python bindings. 314 from GaudiKernel.Proxy.Configurable
import expandvars
320 from GaudiKernel.Proxy.Configurable
import Configurable, getNeededConfigurables
323 if _bootstrap
is None:
326 self.log.debug(
'basicInit: instantiate ApplicationMgr')
327 self.
ip = self.
g = _bootstrap.createApplicationMgr()
329 self.log.debug(
'basicInit: apply options')
332 comp =
'ApplicationMgr' 333 props = Configurable.allConfigurables.get(comp, {})
335 props =
expandvars(props.getValuedProperties())
336 for p, v
in props.items() + [(
'JobOptionsType',
'NONE')]:
337 if not self.g.setProperty(p, str(v)):
338 self.log.error(
'Cannot set property %s.%s to %s', comp, p, v)
341 if _bootstrap.ROOT_VERSION < (6, 2, 7):
349 msp = self.g.getService(comp)
351 self.log.error(
'Cannot get service %s', comp)
353 props = Configurable.allConfigurables.get(comp, {})
355 props =
expandvars(props.getValuedProperties())
356 for p, v
in props.items():
357 if not _bootstrap.setProperty(msp, p, str(v)):
358 self.log.error(
'Cannot set property %s.%s to %s', comp, p, v)
362 comp =
'JobOptionsSvc' 363 jos = self.g.getService(comp)
365 self.log.error(
'Cannot get service %s', comp)
368 c = Configurable.allConfigurables[n]
369 if n
in [
'ApplicationMgr',
'MessageSvc']:
371 for p, v
in c.getValuedProperties().items():
374 if hasattr(Configurable,
"PropertyReference")
and type(
375 v) == Configurable.PropertyReference:
381 elif type(v) == long:
383 _bootstrap.addPropertyToCatalogue(jos, n, p, str(v))
384 if hasattr(Configurable,
"_configurationLocked"):
385 Configurable._configurationLocked =
True 386 self.log.debug(
'basicInit: done')