From e2e679269a64cda4f814c58a7a10053dd046fea0 Mon Sep 17 00:00:00 2001 From: Jordan Adler Date: Fri, 26 Oct 2018 18:17:01 -0700 Subject: [PATCH] Bail if building with Py3 --- setup.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/setup.py b/setup.py index 2f7b36a3..3cad4492 100755 --- a/setup.py +++ b/setup.py @@ -12,6 +12,9 @@ except ImportError: from distutils.core import setup +if sys.argv[-1] == 'sdist' and sys.version_info[0] >= 3: + print('ERROR: You must build python-future with Python 2', file=sys.stderr) + sys.exit(1) if sys.argv[-1] == 'publish': os.system('python setup.py sdist upload')