From 7b7959e9b5cc9a68a6fcffba44bca2f84643b133 Mon Sep 17 00:00:00 2001 From: Al Bailey Date: Tue, 28 Jan 2020 07:49:23 -0600 Subject: [PATCH] Update pylint target for python3 and upper constraints This change imposes the upper constraint in tox to protect from future releases causing random breakage. Ex: A new version of python-libvirt was released Jan 23 2020 which will not install on python2. This change also enables the python3 target for pylint which will allow the upper constraint to be changed to a more recent version when all the tox files are aligned. Change-Id: I9056778085d32b3401df60c20d67cff0a21dfe97 Story: 2004515 Task: 38496 Signed-off-by: Al Bailey --- tox.ini | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/tox.ini b/tox.ini index 1582be921..c51407e81 100644 --- a/tox.ini +++ b/tox.ini @@ -5,7 +5,9 @@ skipsdist = True stxdir = {toxinidir}/.. [testenv] -install_command = pip install -U {opts} {packages} +install_command = pip install -U \ + -c{env:UPPER_CONSTRAINTS_FILE:https://opendev.org/openstack/requirements/raw/branch/stable/stein/upper-constraints.txt} \ + {opts} {packages} setenv = VIRTUAL_ENV={envdir} OS_STDOUT_CAPTURE=1 OS_STDERR_CAPTURE=1 @@ -78,7 +80,7 @@ commands = flake8 [testenv:pylint] -basepython = python2.7 +basepython = python3 deps = -r{toxinidir}/test-requirements.txt -e{[tox]stxdir}/config/tsconfig/tsconfig -e{[tox]stxdir}/fault/fm-api