From 170e8a2b1137c9f04ed17e9bb5025b2b7692d1e1 Mon Sep 17 00:00:00 2001 From: Chris Arderne Date: Thu, 5 Jan 2023 14:26:56 +0000 Subject: [PATCH] Set more open() encoding to utf-8 --- sigexport/main.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sigexport/main.py b/sigexport/main.py index 227812b..55f9ae8 100755 --- a/sigexport/main.py +++ b/sigexport/main.py @@ -126,7 +126,7 @@ def create_markdown( if not name: name = "None" md_path = dest / name / "index.md" - with md_path.open("w") as _: + with md_path.open("w", encoding="utf-8") as _: pass # overwrite file if it exists for msg in messages: @@ -505,7 +505,7 @@ def main( # Read sqlcipher key from Signal config file if source.is_file(): - with open(source) as conf: + with open(source, encoding="utf-8") as conf: key = json.loads(conf.read())["key"] else: secho(f"Error: {source} not found in directory {src}")