diff --git a/app/common.py b/app/common.py index b191964..e4c8af1 100644 --- a/app/common.py +++ b/app/common.py @@ -45,12 +45,12 @@ def secret_key_check(name: SecretKey) -> None: key_file = Path(f'/tmp/{name}') if key_file.exists(): - with key_file.open('rt') as f: + with key_file.open('rt', encoding='utf-8') as f: key = f.read() else: key = secrets.token_hex(32) - with key_file.open('wt') as f: + with key_file.open('wt', encoding='utf-8') as f: f.write(key) settings_dict[name] = key