software/ors-amarisoft: test: Avoid YAMLLoadWarning warning
Currently on every test yaml.load issues a warning that using it without explicitly specifying loader is deprecated, for example: test_enb_conf (testTDD.TestENBParameters) .../slapos/software/ors-amarisoft/test/test.py:29: YAMLLoadWarning: calling yaml.load() without Loader=... is deprecated, as the default Loader is unsafe. Please read https://msg.pyyaml.org/load for full details. -> Fix the warning by using appropriate loader explicitly. Use FullLoader since msg.pyyaml.org/load describes it as Loads the full YAML language. Avoids arbitrary code execution. This is currently (PyYAML 5.1+) the default loader called by yaml.load(input) (after issuing the warning). i.e. we get support for full YAML feature set, do not get code execution and make sure that the behaviour stays exactly the same as before, but without the warning. /cc @jhuge, @lu.xu, @tomo, @xavier_thompson, @Daetalus /proposed-for-review-on nexedi/slapos!1526 /reviewed-by TrustMe
Showing
Please register or sign in to comment