diff options
author | Jason R. Coombs <jaraco@jaraco.com> | 2015-12-09 03:34:35 -0500 |
---|---|---|
committer | Jason R. Coombs <jaraco@jaraco.com> | 2015-12-09 03:34:35 -0500 |
commit | 41112f5afd0d2b0c14899ab1cf2c27183e64d6ac (patch) | |
tree | 81c6998dea813de0f146b2c58125f1226cbadad3 /setuptools/command/build_py.py | |
parent | 1c7e97f95ea74c241b91dfb975c709940ba00f47 (diff) | |
download | python-setuptools-git-41112f5afd0d2b0c14899ab1cf2c27183e64d6ac.tar.gz |
Use io.open for future compatibility and consistency
Diffstat (limited to 'setuptools/command/build_py.py')
-rw-r--r-- | setuptools/command/build_py.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/setuptools/command/build_py.py b/setuptools/command/build_py.py index b2dafec9..8a50f032 100644 --- a/setuptools/command/build_py.py +++ b/setuptools/command/build_py.py @@ -163,7 +163,7 @@ class build_py(orig.build_py, Mixin2to3): with io.open(init_py, 'rb') as f: contents = f.read() - if b'declare_namespace' not in f.read(): + if b'declare_namespace' not in contents: raise distutils.errors.DistutilsError( "Namespace package problem: %s is a namespace package, but " "its\n__init__.py does not call declare_namespace()! Please " |