[Python-modules-commits] [txzmq] 07/11: Use io.open when reading UTF-8 encoded file for Python3 compatibility.

Michael Fladischer fladi at moszumanska.debian.org
Fri May 20 18:06:29 UTC 2016


This is an automated email from the git hooks/post-receive script.

fladi pushed a commit to branch master
in repository txzmq.

commit 044ccd42964a7a786b03a1fa4503c21614b6ffec
Author: Michael Fladischer <FladischerMichael at fladi.at>
Date:   Fri May 20 19:34:00 2016 +0200

    Use io.open when reading UTF-8 encoded file for Python3 compatibility.
---
 setup.py | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/setup.py b/setup.py
index f179891..1ae7540 100644
--- a/setup.py
+++ b/setup.py
@@ -1,14 +1,16 @@
+import io
+
 from distutils.core import setup
 
 setup(
     name='txZMQ',
-    version=open('VERSION').read().strip(),
+    version=io.open('VERSION', encoding='utf-8').read().strip(),
     packages=['txzmq', 'txzmq.test'],
     license='GPLv2',
     author='Andrey Smirnov',
     author_email='me at smira.ru',
     url='https://github.com/smira/txZMQ',
     description='Twisted bindings for ZeroMQ',
-    long_description=open('README.rst').read(),
+    long_description=io.open('README.rst', encoding='utf-8').read(),
     install_requires=["Twisted>=10.0", "pyzmq>=13"],
 )

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/python-modules/packages/txzmq.git



More information about the Python-modules-commits mailing list