setup: sys.version_info always exists

It is documented as existing since Python 2.0, and empirically from
other OSS projects I maintain, there is no problem relying on its
existance.
This commit is contained in:
Alex Gaynor 2017-05-03 09:41:55 -04:00
parent 3c7a9be1c9
commit 7152638545

View File

@ -5,7 +5,7 @@
# 'python setup.py --help' for more options
import sys, platform
if getattr(sys, 'version_info', (0, 0, 0)) < (2, 6, 0, 'final'):
if sys.version_info < (2, 6, 0, 'final'):
raise SystemExit("Mercurial requires Python 2.6 or later.")
if sys.version_info[0] >= 3: