Don't sort keys when dumping json and yaml (#39214)

This commit is contained in:
Bram Kragten authored and GitHub committed 2020-08-24 16:58:27 +02:00
1 parent 181709f3d2
commit 28332f23b3
3 files changed
+5 -7

No files matched your search

+1 -1
View File
@@ -54,7 +54,7 @@ def save_json(
Returns True on success.
"""
try:
json_data = json.dumps(data, sort_keys=True, indent=4, cls=encoder)
json_data = json.dumps(data, indent=4, cls=encoder)
except TypeError:
msg = f"Failed to serialize to JSON: {filename}. Bad data at {format_unserializable_data(find_paths_unserializable_data(data))}"
_LOGGER.error(msg)