From cc91386015f2dc3a55b82b384567216f684d3fb6 Mon Sep 17 00:00:00 2001 From: Chris Burr Date: Thu, 14 Jan 2021 10:25:50 +0100 Subject: [PATCH] Modify __init__.py to avoid conflicts with rel-v7r2 --- __init__.py | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/__init__.py b/__init__.py index 310453b8232..b70a41b41d8 100755 --- a/__init__.py +++ b/__init__.py @@ -88,12 +88,15 @@ import _strptime -# Define Version - -majorVersion = 7 -minorVersion = 0 -patchLevel = 44 -preVersion = 0 +# Define Version, use an unsual structure to minimise conflicts with rel-v7r2 +pythonVersion = pyPlatform.python_version_tuple() +if pythonVersion[0] == "3": + pass +else: + majorVersion = 7 + minorVersion = 0 + patchLevel = 44 + preVersion = 0 version = "v%sr%s" % (majorVersion, minorVersion) buildVersion = "v%dr%d" % (majorVersion, minorVersion) @@ -108,8 +111,6 @@ __pythonMajorVersion = ("2", ) __pythonMinorVersion = ("7") - -pythonVersion = pyPlatform.python_version_tuple() if str(pythonVersion[0]) not in __pythonMajorVersion or str(pythonVersion[1]) not in __pythonMinorVersion: print("Python Version %s not supported by DIRAC" % pyPlatform.python_version()) print("Supported versions are: ")