Skip to content
Snippets Groups Projects
Commit 4d7199f6 authored by Marcin Nowak's avatar Marcin Nowak :radioactive: Committed by Julien Maurer
Browse files

Fixed python error in setting output amitag - see ATLASRECTS-6865

Fixed python error in setting output amitag - see ATLASRECTS-6865
parent a2a06d9b
No related branches found
No related tags found
No related merge requests found
......@@ -114,14 +114,14 @@ def SetAMITag(outputTag=None, inputTags=None, runArgs=None):
if not inputTags:
inputTags = InputAMITags()
tags = inputTags
if outputTag and outputTag not in inputTags:
tags += [outputTag]
tags = [tag for tag in tags if amitagRegex.match(tag)]
amitag = '_'.join(tags)
try:
if outputTag not in inputTags:
tags = inputTags + [outputTag]
tags = [tag for tag in tags if amitagRegex.match(tag)]
amitag = '_'.join(tags)
if amitag:
ServiceMgr.TagInfoMgr.ExtraTagValuePairs.update(
{'AMITag': amitag})
ServiceMgr.TagInfoMgr.ExtraTagValuePairs.update( {'AMITag': amitag})
log.info("Output AMITag in in-file metadata set to {}".format(amitag))
else:
log.debug("Not adding empty AMITag to /TagInfo")
......
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