[Asterisk-code-review] Remove YAMLLoadWarning: calling yaml.load() (II) (...testsuite[certified/13.21])
Kevin Harwell
asteriskteam at digium.com
Fri May 3 09:31:15 CDT 2019
Kevin Harwell has submitted this change and it was merged. ( https://gerrit.asterisk.org/c/testsuite/+/11342 )
Change subject: Remove YAMLLoadWarning: calling yaml.load() (II)
......................................................................
Remove YAMLLoadWarning: calling yaml.load() (II)
As commit cac597f96670b994727f6fe98f17c70eefa5f635 remove use of plan
for yaml.load without Loader deprecated from PyYAML 5.1
Change-Id: Ie29b2709c6110a721dc93a824a9ae4bc2adc0d46
---
M lib/python/asterisk/test_runner.py
M usage.py
2 files changed, 2 insertions(+), 2 deletions(-)
Approvals:
Kevin Harwell: Looks good to me, approved; Approved for Submit
diff --git a/lib/python/asterisk/test_runner.py b/lib/python/asterisk/test_runner.py
index 644d117..5b115d3 100755
--- a/lib/python/asterisk/test_runner.py
+++ b/lib/python/asterisk/test_runner.py
@@ -227,7 +227,7 @@
return test_config
with open(test_config_path) as file_stream:
- test_config = yaml.load(file_stream, )
+ test_config = yaml.load(file_stream, Loader=yaml.SafeLoader)
return test_config
diff --git a/usage.py b/usage.py
index 16dea94..fe18e27 100755
--- a/usage.py
+++ b/usage.py
@@ -101,7 +101,7 @@
print "Unexpected error: %s" % sys.exc_info()[0]
return None
- config = yaml.load(f)
+ config = yaml.load(f, Loader=yaml.SafeLoader)
f.close()
return config
--
To view, visit https://gerrit.asterisk.org/c/testsuite/+/11342
To unsubscribe, or for help writing mail filters, visit https://gerrit.asterisk.org/settings
Gerrit-Project: testsuite
Gerrit-Branch: certified/13.21
Gerrit-Change-Id: Ie29b2709c6110a721dc93a824a9ae4bc2adc0d46
Gerrit-Change-Number: 11342
Gerrit-PatchSet: 1
Gerrit-Owner: George Joseph <gjoseph at digium.com>
Gerrit-Reviewer: Kevin Harwell <kharwell at digium.com>
Gerrit-Reviewer: Rodrigo Ramirez Norambuena <a at rodrigoramirez.com>
Gerrit-MessageType: merged
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20190503/0d3ca735/attachment-0001.html>
More information about the asterisk-code-review
mailing list