Skip to content

Commit 797d892

Browse files
alexpantyukhinasvetlov
authored andcommitted
fix setup to read version on windows (#145)
* fix setup to read version on windows * remove redundat parameter U
1 parent c5c39ce commit 797d892

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

setup.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
import codecs
21
from setuptools import setup, find_packages
32
import os
43
import re
@@ -16,8 +15,8 @@ def run(self):
1615
raise SystemExit(errno)
1716

1817

19-
with codecs.open(os.path.join(os.path.abspath(os.path.dirname(
20-
__file__)), 'aiohttp_security', '__init__.py'), 'r', 'latin1') as fp:
18+
with open(os.path.join(os.path.abspath(os.path.dirname(
19+
__file__)), 'aiohttp_security', '__init__.py'), 'r', encoding='latin1') as fp:
2120
try:
2221
version = re.findall(r"^__version__ = '([^']+)'$", fp.read(), re.M)[0]
2322
except IndexError:

0 commit comments

Comments
 (0)