aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMilosz Wasilewski <milosz.wasilewski@linaro.org>2020-03-02 11:38:02 +0000
committerMilosz Wasilewski <milosz.wasilewski@linaro.org>2020-03-02 11:39:52 +0000
commit1097c990eac1cbdd136082290c157faf6224ada8 (patch)
tree49dcad1a54160ee095c974fa205b1427edb627d5
parentacd670b391ea4dcd2b90a69bd9bc916b9d764d4b (diff)
validate: fix YAML load() warnings
Signed-off-by: Milosz Wasilewski <milosz.wasilewski@linaro.org>
-rwxr-xr-xvalidate.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/validate.py b/validate.py
index 6bf199ff..196a31fb 100755
--- a/validate.py
+++ b/validate.py
@@ -133,7 +133,7 @@ def validate_yaml_contents(filepath, args):
except FileNotFoundError:
publish_result(["* YAMLVALIDCONTENTS [PASSED]: " + filepath + " - deleted"], args)
return 0
- y = yaml.load(filecontent)
+ y = yaml.load(filecontent, Loader=yaml.FullLoader)
if 'run' in y.keys():
# test definition yaml file
return validate_testdef_yaml(y, args)
@@ -154,7 +154,7 @@ def validate_yaml(filename, args):
publish_result(["* YAMLVALID [PASSED]: " + filename + " - deleted"], args)
return 0
try:
- yaml.load(filecontent)
+ yaml.load(filecontent, Loader=yaml.FullLoader)
message = "* YAMLVALID: [PASSED]: " + filename
print_stderr(message)
except yaml.YAMLError: