From a1fff4a080d1148599c30b074a8dcbb37475701f Mon Sep 17 00:00:00 2001 From: Jon Dufresne Date: Thu, 24 Dec 2020 14:13:52 -0800 Subject: Replace io.open() and codecs.open() with builtin open() In Python 3, these are functionally equivalent and share the same feature set. --- setup.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'setup.py') diff --git a/setup.py b/setup.py index b7d0e8f51..b3aaa3613 100644 --- a/setup.py +++ b/setup.py @@ -1,7 +1,6 @@ # The following comment should be removed at some point in the future. # mypy: disallow-untyped-defs=False -import codecs import os import sys @@ -12,7 +11,7 @@ def read(rel_path): here = os.path.abspath(os.path.dirname(__file__)) # intentionally *not* adding an encoding option to open, See: # https://github.com/pypa/virtualenv/issues/201#issuecomment-3145690 - with codecs.open(os.path.join(here, rel_path), 'r') as fp: + with open(os.path.join(here, rel_path), 'r') as fp: return fp.read() -- cgit v1.2.1