diff --git a/tools/yaml-validate.py b/tools/yaml-validate.py index b4e135e204..bb9f1572f5 100755 --- a/tools/yaml-validate.py +++ b/tools/yaml-validate.py @@ -1162,12 +1162,14 @@ def validate_network_data_file(data_file_path): data_file = yaml.load(open(data_file_path).read()) base_file_path = os.path.dirname(data_file_path) + "/network_data.yaml" base_file = yaml.load(open(base_file_path).read()) + retval = 0 for n in base_file: if n not in data_file: print('ERROR: The following network from network_data.yaml is ' 'missing or differs in %s : %s' % (data_file_path, n)) - return 1 + retval = 1 + return retval except Exception: print(traceback.format_exc()) return 1