summary refs log tree commit diff
diff options
context:
space:
mode:
authorBrendan Abolivier <babolivier@matrix.org>2019-09-09 16:34:47 +0100
committerBrendan Abolivier <babolivier@matrix.org>2019-09-09 16:34:47 +0100
commit21a6f0b12c3e0db147b73b26fa465460f46a3bd8 (patch)
tree2a2229e6883e4ba0c13d54f9f92ef9b5f825ebe1
parentRevert "Ensure the password reset template is correctly converted to binary" (diff)
downloadsynapse-21a6f0b12c3e0db147b73b26fa465460f46a3bd8.tar.xz
Read all files as UTF-8
-rw-r--r--synapse/config/_base.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/synapse/config/_base.py b/synapse/config/_base.py

index f7d7f153bb..ae05667a40 100644 --- a/synapse/config/_base.py +++ b/synapse/config/_base.py
@@ -15,6 +15,7 @@ import argparse import errno +from io import open import os from textwrap import dedent @@ -131,7 +132,7 @@ class Config(object): @classmethod def read_file(cls, file_path, config_name): cls.check_file(file_path, config_name) - with open(file_path) as file_stream: + with open(file_path, encoding="utf-8") as file_stream: return file_stream.read() @staticmethod