From 51a918730815fa8f932409417d950161b3085c3d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20P=C3=A9ters?= Date: Fri, 29 Jul 2016 23:27:29 +0200 Subject: [PATCH] misc: python 3 compatibility (#12805) --- setup.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/setup.py b/setup.py index 9f67b4d..289df2e 100644 --- a/setup.py +++ b/setup.py @@ -18,7 +18,7 @@ from setuptools import setup, find_packages class eo_sdist(sdist): def run(self): - print "creating VERSION file" + print("creating VERSION file") if os.path.exists('VERSION'): os.remove('VERSION') version = get_version() @@ -26,7 +26,7 @@ class eo_sdist(sdist): version_file.write(version) version_file.close() sdist.run(self) - print "removing VERSION file" + print("removing VERSION file") if os.path.exists('VERSION'): os.remove('VERSION') @@ -42,7 +42,7 @@ def get_version(): stdout=subprocess.PIPE, stderr=subprocess.PIPE) result = p.communicate()[0] if p.returncode == 0: - return result.split()[0][1:].replace('-', '.') + return result.decode('ascii').split()[0][1:].replace('-', '.') else: return '0.0.0-%s' % len( subprocess.check_output( -- 2.8.1