community-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From s...@apache.org
Subject svn commit: r1878436 - /comdev/projects.apache.org/trunk/scripts/cronjobs/parsecommitteeinfo.py
Date Wed, 03 Jun 2020 14:15:55 GMT
Author: sebb
Date: Wed Jun  3 14:15:55 2020
New Revision: 1878436

URL: http://svn.apache.org/viewvc?rev=1878436&view=rev
Log:
Email errors; allow skip of image checks

Modified:
    comdev/projects.apache.org/trunk/scripts/cronjobs/parsecommitteeinfo.py

Modified: comdev/projects.apache.org/trunk/scripts/cronjobs/parsecommitteeinfo.py
URL: http://svn.apache.org/viewvc/comdev/projects.apache.org/trunk/scripts/cronjobs/parsecommitteeinfo.py?rev=1878436&r1=1878435&r2=1878436&view=diff
==============================================================================
--- comdev/projects.apache.org/trunk/scripts/cronjobs/parsecommitteeinfo.py (original)
+++ comdev/projects.apache.org/trunk/scripts/cronjobs/parsecommitteeinfo.py Wed Jun  3 14:15:55
2020
@@ -83,6 +83,8 @@ def head(url):
 pmcs = {}
 pmcDataUrls = {} # id -> url
 
+skipImageTest = len(sys.argv) >= 2 and sys.argv[1] == '--skipImageTest'
+
 # get PMC Data from /data/committees.xml
 print("Reading PMC Data (/data/committees.xml)")
 with open("../../data/committees.xml", "r") as f:
@@ -131,7 +133,7 @@ for loc in xmldoc.getElementsByTagName('
         pmcs[committeeId] = pmcjson
 
     except Exception as err:
-        print("ERROR: %s processing %s" % (err, url), file=sys.stderr)
+        printMail("ERROR: %s processing %s" % (err, url))
 
 committeeCount = 0
 committeesList = []
@@ -176,7 +178,7 @@ for group in sorted(committees, key=keyo
                 committeeId = group
 
             img = "http://www.apache.org/logos/res/%s/default.png" % committeeId
-            if not head(img):
+            if not skipImageTest and not head(img):
                 print("WARN: could not find logo: %s" % (img))
                 
             committeeCount += 1



Mime
View raw message