From 834468e8e75a3c0b084a1b0287b90ea2dc1edeab Mon Sep 17 00:00:00 2001 From: Thomas Grainger Date: Tue, 2 May 2017 17:37:17 +0100 Subject: [PATCH] fix README.rst -> long_description encoding --- setup.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/setup.py b/setup.py index 5784283b..17f2c67e 100644 --- a/setup.py +++ b/setup.py @@ -10,7 +10,7 @@ from distutils.util import strtobool from setuptools import setup -def open_local(paths, mode='r', encoding='latin1'): +def open_local(paths, mode='r', encoding='utf8'): path = os.path.join( os.path.abspath(os.path.dirname(__file__)), *paths @@ -19,7 +19,7 @@ def open_local(paths, mode='r', encoding='latin1'): return codecs.open(path, mode, encoding) -with open_local(['sanic', '__init__.py']) as fp: +with open_local(['sanic', '__init__.py'], encoding='latin1') as fp: try: version = re.findall(r"^__version__ = '([^']+)'\r?$", fp.read(), re.M)[0]