Skip to content

Interactive interface for browsing global, full-resolution satellite imagery

add check to see if layers in event config are in layer config

Benjamin King384b06f90c3a
diff --git a/tasks/validateOptions.py b/tasks/validateOptions.py
index c0701e9bf..30c2b7373 100755
--- a/tasks/validateOptions.py
+++ b/tasks/validateOptions.py
@@ -158,6 +158,13 @@ for startingLayer in wv["defaults"]["startingLayers"]:
wv["defaults"]["startingLayers"] = startingLayers
wv["buildDate"] = datetime.now().isoformat(" ")
+for projection, projectionValue in wv["naturalEvents"]["layers"].iteritems():
+ for eventType, eventTypeLayerList in projectionValue.iteritems():
+ for layerObject in eventTypeLayerList:
+ if layerObject[0] not in wv["layers"]:
+ error("The %s layer in the Natural events %s %s config does not have a matching ID in the layer config" %
+ (layerObject[0], projection, eventType))
+
for measurement in wv["measurements"].values():
if "sources" not in measurement:
continue