Skip to content
Snippets Groups Projects
Commit a1e2901c authored by zhuzeyu's avatar zhuzeyu
Browse files

Use yaml.safe_dump() instead of yaml.dump()

Remove Python specific types from YAML output
Produce only basic YAML tags

Change-Id: Ib6a4c18663897efb7243ed1ff84df1c9f2abf8bf
parent 04ebda9e
No related branches found
No related tags found
No related merge requests found
......@@ -112,7 +112,7 @@ def main():
])
with open(passwords_file, 'w') as f:
f.write(yaml.dump(passwords, default_flow_style=False))
f.write(yaml.safe_dump(passwords, default_flow_style=False))
if __name__ == '__main__':
main()
......@@ -32,7 +32,7 @@ def main():
new_passwords.update(old_passwords)
with open(args.final, "w") as destination:
yaml.dump(new_passwords, destination, default_flow_style=False)
yaml.safe_dump(new_passwords, destination, default_flow_style=False)
if __name__ == '__main__':
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment