From 51002230b69931fa07c9255324d598e5df516ce0 Mon Sep 17 00:00:00 2001
From: Spyridon Argyropoulos <spyridon.argyropoulos@cern.ch>
Date: Sun, 1 Mar 2020 10:07:03 +0100
Subject: [PATCH] Add check for AthGeneration in logParser

---
 scripts/logParser.py | 15 ++++++++++-----
 1 file changed, 10 insertions(+), 5 deletions(-)

diff --git a/scripts/logParser.py b/scripts/logParser.py
index 8cdb13955f..1b9ba1bd86 100644
--- a/scripts/logParser.py
+++ b/scripts/logParser.py
@@ -236,13 +236,18 @@ def main():
         name='using release'
         tmp=JOsDict[name][0].replace('using release','').strip().split()[0]
         val=tmp.replace('[','').replace(']','')
+        flavour=val.split('-')[0]
         release=val.split('-')[1]
-        #checkForBlacklist
-        blacklisted=checkBlackList(val.split('-')[0],val.split('-')[1],".",JOsList,location=location)
-        if blacklisted:
-            logerr( '- '+name+' = ',"".join(val)+" <-- ERROR: %s"%blacklisted)
+        blacklisted=checkBlackList(flavour,release,".",JOsList,location=location)
+        # check that release is AthGeneration
+        if flavour != "AthGeneration":
+            logerr( '- '+name+' = ',"".join(val)+f" <-- ERROR: AthGeneration should be used instead of {flavour}")
         else:
-            loggood( '- '+name+' = ',"".join(val))
+            # check blacklist
+            if blacklisted:
+                logerr( '- '+name+' = ',"".join(val)+" <-- ERROR: %s"%blacklisted)
+            else:
+                loggood( '- '+name+' = ',"".join(val))
      
     
     if len(JOsErrors):
-- 
GitLab