python-guide
python-guide copied to clipboard
Update yaml.load() to avoid warning
The yaml.load() function call throws the following warning when Loader isn't specified:
"YAMLLoadWarning: calling yaml.load() without Loader=... is deprecated, as the default Loader is unsafe. Please read https://msg.pyyaml.org/load for full details."
The updated default loader avoids arbitrary code execution after issuing a warning, however the warning can be avoided with yaml.load(input, Loader=