Skip to content
Snippets Groups Projects
Commit 03837e06 authored by Vakhtang Tsulaia's avatar Vakhtang Tsulaia
Browse files

Merge branch 'maszyman-atlasrects-6952' into 'master'

RecExCommon_topOptions: check if ByteStreamMetadataTool in MetadataTools

Closes ATLASRECTS-6952

See merge request !58818
parents 7b0b8250 0111f8f5
No related branches found
No related tags found
4 merge requests!59674InDetPerformanceMonitoring with LumiBlock selection,!59383cppcheck in trigger code: Prefer prefix ++/-- operators for non-primitive types.,!58990Draft:Fixing bug in FTF config when running with Reco_tf,!58818RecExCommon_topOptions: check if ByteStreamMetadataTool in MetadataTools
# Copyright (C) 2002-2019 CERN for the benefit of the ATLAS collaboration
# Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
###############################################################
#
......@@ -64,6 +64,6 @@ if not hasattr (svcMgr.ToolSvc, 'IOVDbMetaDataTool'):
svcMgr.ToolSvc += CfgMgr.IOVDbMetaDataTool()
# Enable ByteStream to read MetaData
svcMgr.MetaDataSvc.MetaDataTools += [ "ByteStreamMetadataTool" ]
if not hasattr (svcMgr.ToolSvc, 'ByteStreamMetadataTool'):
svcMgr.ToolSvc += CfgMgr.ByteStreamMetadataTool()
svcMgr.MetaDataSvc.MetaDataTools += [ "ByteStreamMetadataTool" ]
......@@ -721,21 +721,19 @@ if rec.doFileMetaData():
ToolSvc += CfgMgr.xAODMaker__FileMetaDataTool( "FileMetaDataTool" )
svcMgr.MetaDataSvc.MetaDataTools += [ ToolSvc.FileMetaDataTool ]
try:
# we want ByteStreamMetadata to propagate only through ESD and AOD
from ByteStreamCnvSvc.ByteStreamCnvSvcConf import ByteStreamMetadataTool
if not hasattr (svcMgr.ToolSvc, "ByteStreamMetadataTool"):
ToolSvc += ByteStreamMetadataTool()
if "ByteStreamMetadataTool" not in str(svcMgr.MetaDataSvc.MetaDataTools):
svcMgr.MetaDataSvc.MetaDataTools += [ ToolSvc.ByteStreamMetadataTool ]
except Exception:
treatException("Could not load ByteStreamMetadataTool")
else:
# Create LumiBlock meta data containers *before* creating the output StreamESD/AOD
include ("LumiBlockComps/CreateLumiBlockFromFile_jobOptions.py")
pass
try:
# ByteStreamMetadata
from ByteStreamCnvSvc.ByteStreamCnvSvcConf import ByteStreamMetadataTool
if not hasattr (svcMgr.ToolSvc, 'ByteStreamMetadataTool'):
ToolSvc += ByteStreamMetadataTool()
svcMgr.MetaDataSvc.MetaDataTools += [ ToolSvc.ByteStreamMetadataTool ]
except Exception:
treatException("Could not load ByteStreamMetadataTool")
pass
##--------------------------------------------------------
###=== Only run reco on events that pass selected triggers
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment