From b60d35f231db44a3f32f395e6c52c6b0ec6aabe9 Mon Sep 17 00:00:00 2001 From: Stephan Date: Sun, 1 Nov 2020 21:44:16 +0100 Subject: [PATCH] Do not convert cleaned up locale message file to ascii --- .script/build_extension.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.script/build_extension.py b/.script/build_extension.py index a15650c..38fb2d7 100644 --- a/.script/build_extension.py +++ b/.script/build_extension.py @@ -43,15 +43,15 @@ def remove_dir(top): # ------------------------------------------------------- def cleanup_locale_messages(msg_path): - with open(msg_path, 'r', encoding='utf-8') as f: - messages = load(f) + with open(msg_path, 'r', encoding='utf-8') as json_file: + messages = load(json_file) for key in messages: if "description" in messages[key]: del messages[key]["description"] - with open(msg_path, 'w') as f: - dump(messages, f, sort_keys=False, indent=2, ensure_ascii=True) + with open(msg_path, 'w', encoding='utf-8') as json_file: + dump(messages, json_file, sort_keys=False, indent=2, ensure_ascii=False) # -------------------------------------------------------