From 83dc981ce37689d121db72d0a882d192e4b48bec Mon Sep 17 00:00:00 2001 From: Aaron LI Date: Fri, 30 Sep 2016 16:54:53 +0800 Subject: setup.py: Check Python >= 3.4 before installation --- setup.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/setup.py b/setup.py index 9f5d0b2..1d8a7e3 100755 --- a/setup.py +++ b/setup.py @@ -6,6 +6,7 @@ # import os +import sys from setuptools import setup, find_packages @@ -16,6 +17,11 @@ def read(fname): return open(os.path.join(os.path.dirname(__file__), fname)).read() +# Check the minimal Python version +if sys.version_info < (3, 4): + sys.exit("Sorry, Python >= 3.4 is required...") + + setup( name=pkg.__pkgname__, version=pkg.__version__, -- cgit v1.2.2