summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZuul <zuul@review.opendev.org>2022-11-17 15:07:24 +0000
committerGerrit Code Review <review@openstack.org>2022-11-17 15:07:24 +0000
commit052c5cc4b4ed494600612018da4482213f4edc5f (patch)
tree43bcaea50ed3608b80792667e8f343cb528a9066
parent0df64d5af92b46457fd3f13aceb69b4f94b8b53c (diff)
parentb07dd1d2f8f7adbf91392694534b333893b8d508 (diff)
downloadglance_store-052c5cc4b4ed494600612018da4482213f4edc5f.tar.gz
Merge "Remove logic for Python <= 2.6"
-rw-r--r--tools/colorizer.py6
-rw-r--r--tools/install_venv.py1
-rw-r--r--tools/install_venv_common.py7
3 files changed, 1 insertions, 13 deletions
diff --git a/tools/colorizer.py b/tools/colorizer.py
index d26df6f..d82c998 100644
--- a/tools/colorizer.py
+++ b/tools/colorizer.py
@@ -322,11 +322,7 @@ class SubunitTestResult(testtools.TestResult):
test = subunit.ProtocolTestCase(sys.stdin, passthrough=None)
-if sys.version_info[0:2] <= (2, 6):
- runner = unittest.TextTestRunner(verbosity=2)
-else:
- runner = unittest.TextTestRunner(
- verbosity=2, resultclass=SubunitTestResult)
+runner = unittest.TextTestRunner(verbosity=2, resultclass=SubunitTestResult)
if runner.run(test).wasSuccessful():
exit_code = 0
diff --git a/tools/install_venv.py b/tools/install_venv.py
index acc0e6f..fc17979 100644
--- a/tools/install_venv.py
+++ b/tools/install_venv.py
@@ -59,7 +59,6 @@ def main(argv):
install = install_venv.InstallVenv(root, venv, pip_requires, test_requires,
py_version, project)
options = install.parse_args(argv)
- install.check_python_version()
install.check_dependencies()
install.create_virtualenv(no_site_packages=options.no_site_packages)
install.install_dependencies()
diff --git a/tools/install_venv_common.py b/tools/install_venv_common.py
index d73649c..159a1ad 100644
--- a/tools/install_venv_common.py
+++ b/tools/install_venv_common.py
@@ -16,9 +16,6 @@
"""Provides methods needed by installation script for OpenStack development
virtual environments.
-Since this script is used to bootstrap a virtualenv from the system's Python
-environment, it should be kept strictly compatible with Python 2.6.
-
Synced in from openstack-common
"""
@@ -44,10 +41,6 @@ class InstallVenv(object):
print(message % args, file=sys.stderr)
sys.exit(1)
- def check_python_version(self):
- if sys.version_info < (2, 6):
- self.die("Need Python Version >= 2.6")
-
def run_command_with_code(self, cmd, redirect_output=True,
check_exit_code=True):
"""Runs a command in an out-of-process shell.