From 022f391071bbc9eae3747549d0eea8b23b4edf67 Mon Sep 17 00:00:00 2001
From: John Kenneth Anders <john.kenneth.anders@cern.ch>
Date: Wed, 12 Dec 2018 17:22:01 +0000
Subject: [PATCH] Merge branch 'tilecal-for-21.0' into '21.0'
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

minor update in jobOptions_TileCalibRec.py - preparing to read new RDO

See merge request atlas/athena!16497

(cherry picked from commit c4f256d2297eafd99a2d323c59d2bc4f07608532 [formerly 6236fd6e3172352a3867eb670fa571a5c837d64c])

97ed1ab3 minor update in jobOptions_TileCalibRec.py - preparing to read new RDO
34a55797 minor update in jobOptions_TileCalibRec.py - preparing to read new RDO
3449e920 Merge branch 'tilecal-for-21.0' of https://gitlab.cern.ch:8443/solodkov/athena…
7afdb1df minor update in jobOptions_TileCalibRec.py - preparing to read new RDO
89e22547 Merge branch 'tilecal-for-21.0' of https://gitlab.cern.ch:8443/solodkov/athena…

Former-commit-id: a68f2db3c4583cc680147831616e0f778f0a51d3
---
 .../python/iconfTool/__init__.py              |  0
 .../python/iconfTool/utils/__init__.py        |  0
 .../share/jobOptions_TileCalibRec.py          | 21 +++++++++++++++----
 3 files changed, 17 insertions(+), 4 deletions(-)
 mode change 100755 => 100644 Control/AthenaConfiguration/python/iconfTool/__init__.py
 mode change 100644 => 100755 Control/AthenaConfiguration/python/iconfTool/utils/__init__.py

diff --git a/Control/AthenaConfiguration/python/iconfTool/__init__.py b/Control/AthenaConfiguration/python/iconfTool/__init__.py
old mode 100755
new mode 100644
diff --git a/Control/AthenaConfiguration/python/iconfTool/utils/__init__.py b/Control/AthenaConfiguration/python/iconfTool/utils/__init__.py
old mode 100644
new mode 100755
diff --git a/TileCalorimeter/TileExample/TileRecEx/share/jobOptions_TileCalibRec.py b/TileCalorimeter/TileExample/TileRecEx/share/jobOptions_TileCalibRec.py
index 1420c85fbf0..6bee6840436 100644
--- a/TileCalorimeter/TileExample/TileRecEx/share/jobOptions_TileCalibRec.py
+++ b/TileCalorimeter/TileExample/TileRecEx/share/jobOptions_TileCalibRec.py
@@ -637,6 +637,9 @@ from AthenaCommon.BeamFlags import jobproperties
 #jobproperties.Beam.beamType.set_Value_and_Lock('cosmics')
 jobproperties.Beam.beamType.set_Value_and_Lock('collisions')
 
+from AthenaCommon.AthenaCommonFlags import athenaCommonFlags
+athenaCommonFlags.FilesInput.set_Value_and_Lock(FileNameVec)
+
 from AthenaCommon.DetFlags import DetFlags
 DetFlags.Calo_setOff()  #Switched off to avoid geometry
 DetFlags.ID_setOff()
@@ -651,8 +654,6 @@ DetFlags.detdescr.LAr_setOn()
 DetFlags.detdescr.Tile_setOn()
 if TileL1CaloRun:
     DetFlags.detdescr.LVL1_setOn()
-    from AthenaCommon.AthenaCommonFlags import athenaCommonFlags
-    athenaCommonFlags.FilesInput.set_Value_and_Lock(FileNameVec)
 if ReadPool:
     DetFlags.readRDOPool.Tile_setOn()
     if TileL1CaloRun:
@@ -827,8 +828,20 @@ if not OfcFromCOOL and (doTileOpt2 or doTileOptATLAS or doTileOF1):
 from AthenaCommon.AlgSequence import AlgSequence
 topSequence = AlgSequence()
 
-from xAODEventInfoCnv.xAODEventInfoCreator import xAODMaker__EventInfoCnvAlg
-topSequence+=xAODMaker__EventInfoCnvAlg()
+if not 'newRDO' in dir() or newRDO is None:
+    if 'ReadRDO' in dir() and ReadRDO:
+        from RecExConfig.InputFilePeeker import inputFileSummary
+        from RecExConfig.ObjKeyStore import objKeyStore
+        objKeyStore.addManyTypesInputFile(inputFileSummary['eventdata_itemsList'])
+        newRDO = objKeyStore.isInInput( "xAOD::EventInfo" )
+    else:
+        newRDO = True
+
+if ReadPool and newRDO:
+    topSequence += CfgMgr.xAODMaker__EventInfoNonConstCnvAlg()
+else:
+    from xAODEventInfoCnv.xAODEventInfoCreator import xAODMaker__EventInfoCnvAlg
+    topSequence+=xAODMaker__EventInfoCnvAlg()
 
 #=============================================================
 #=== read ByteStream and reconstruct data
-- 
GitLab