From 00b2bcf7d664b1526b4eefe157c33113206d6251 Mon Sep 17 00:00:00 2001 From: Tony Breeds Date: Wed, 8 May 2019 17:15:59 -0400 Subject: [PATCH] Cap keyring, scikit-learn, and sphinx on python2 keyring drops py2 support so lets ensure our requirements wont allow us to install 19.X releases on py2. scikit-learn drops support for 3.4 or lower with release 0.21.0. Setting the minimum supported python for both to 3.4 to be consistent with u-c. When we remove the 3.4 constraints we'll also need to fix g-r Similarly sphinx 2.0.0 drop py27 support do express that in global-requirements. There isn't a need to update u-c as they're already correct: $ grep -E '^(Sphinx|keyring)' upper-constraints.txt keyring===18.0.1;python_version=='2.7' keyring===19.0.1;python_version=='3.4' keyring===19.0.1;python_version=='3.5' keyring===19.0.1;python_version=='3.6' Sphinx===1.8.5;python_version=='2.7' Sphinx===2.0.1;python_version=='3.4' Sphinx===2.0.1;python_version=='3.5' Sphinx===2.0.1;python_version=='3.6' This may cause knock-on effects for projects using either of these in lower-constraints, but that's less impactful than all the 'red' in the gate right now Also 'correct' the Sphinx requirement in test-requirements so we get the correct version when running under python2. We need to do this anyway as docs jobs typically run unconstrained Change-Id: If558f184c959e4b63b56dec3ca1571d1034cfe5c --- global-requirements.txt | 9 ++++++--- test-requirements.txt | 3 ++- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/global-requirements.txt b/global-requirements.txt index f270381a97..d8e390b553 100644 --- a/global-requirements.txt +++ b/global-requirements.txt @@ -321,7 +321,8 @@ scrypt # BSD simplejson # MIT six # MIT scipy # BSD -scikit-learn # BSD +scikit-learn<=0.20.0;python_version<='3.4' # BSD +scikit-learn;python_version>='3.5' # BSD setproctitle # BSD # NOTE(yamahata): # bug work around of sqlalchemy @@ -408,7 +409,8 @@ fixtures-git # Apache-2.0 freezegun # Apache-2.0 gabbi # Apache-2.0 kafka-python # Apache-2.0 -keyring # MIT/PSF +keyring<19.0.0;python_version=='2.7' # MIT/PSF +keyring;python_version>='3.4' # MIT/PSF ldappool # MPL # Do not make mock conditional on Python version: we depend on newer code than # in [most] releases of the Python std library. @@ -447,7 +449,8 @@ selenium # Apache-2.0 # Blacklist setuptools 34.0.0-34.3.2 due to https://github.com/pypa/setuptools/issues/951 # Blacklist setuptools 36.2.0 due to https://github.com/pypa/setuptools/issues/1086 setuptools!=24.0.0,!=34.0.0,!=34.0.1,!=34.0.2,!=34.0.3,!=34.1.0,!=34.1.1,!=34.2.0,!=34.3.0,!=34.3.1,!=34.3.2,!=36.2.0 # PSF/ZPL -sphinx!=1.6.6,!=1.6.7 # BSD +sphinx!=1.6.6,!=1.6.7,<2.0.0;python_version=='2.7' # BSD +sphinx!=1.6.6,!=1.6.7;python_version>='3.4' # BSD sphinx-testing # BSD License sphinxcontrib-actdiag # BSD sphinxcontrib-apidoc # BSD diff --git a/test-requirements.txt b/test-requirements.txt index 4582848efe..beeea49255 100644 --- a/test-requirements.txt +++ b/test-requirements.txt @@ -12,5 +12,6 @@ mock>=2.0.0 # BSD bashate>=0.5.1 # Apache-2.0 # this is required for the docs build jobs -sphinx!=1.6.6,!=1.6.7,>=1.6.2 # BSD +sphinx!=1.6.6,!=1.6.7,<2.0.0;python_version=='2.7' # BSD +sphinx!=1.6.6,!=1.6.7;python_version>='3.4' # BSD openstackdocstheme>=1.18.1 # Apache-2.0