Thread (33 messages) 33 messages, 5 authors, 2019-12-13
STALE2411d

[PATCH 02/13] git-p4: make python-2.7 the oldest supported version

From: Yang Zhao <hidden>
Date: 2019-12-07 00:33:49
Subsystem: the rest · Maintainer: Linus Torvalds

Python-2.6 and earlier have been end-of-life'd for many years now, and
we actually already use 2.7-only features in the code. Make the version
check reflect current realities.
---
 git-p4.py | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/git-p4.py b/git-p4.py
index 60c73b6a37..d8f88884db 100755
--- a/git-p4.py
+++ b/git-p4.py
@@ -8,9 +8,8 @@
 # License: MIT <http://www.opensource.org/licenses/mit-license.php>
 #
 import sys
-if sys.hexversion < 0x02040000:
-    # The limiter is the subprocess module
-    sys.stderr.write("git-p4: requires Python 2.4 or later.\n")
+if sys.version_info.major < 3 and sys.version_info.minor < 7:
+    sys.stderr.write("git-p4: requires Python 2.7 or later.\n")
     sys.exit(1)
 import os
 import optparse
-- 
2.21.0.windows.1
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help