[ussuri][goal] Drop python 2.7 support and testing

OpenStack is dropping the py2.7 support in ussuri cycle.

sahara plugins do works with python 3 and the sahara core
does not support python 2.7 anymore anyway.

Complete discussion & schedule can be found in
- http://lists.openstack.org/pipermail/openstack-discuss/2019-October/010142.html
- https://etherpad.openstack.org/p/drop-python2-support

Ussuri Communtiy-wide goal:
https://governance.openstack.org/tc/goals/selected/ussuri/drop-py27.html

Also:
- bump the lower-constraints decorator requirements to a recent one
  to prevent failures;
- drop the obsolete jenkins tox target.

Change-Id: I5806dcb8f13e88a28c0b5e6de449efa9b95b6e73
This commit is contained in:
Luigi Toscano 2020-01-26 22:00:58 +01:00
parent ca99e621fd
commit 62bfa6af46
5 changed files with 13 additions and 20 deletions

View File

@ -2,7 +2,6 @@
templates:
- openstack-cover-jobs
- openstack-lower-constraints-jobs
- openstack-python-jobs
- openstack-python3-ussuri-jobs
- publish-openstack-docs-pti
- check-requirements

View File

@ -7,7 +7,7 @@ cmd2==0.8.0
coverage==4.0
cryptography==2.1
debtcollector==1.2.0
decorator==3.4.0
decorator==4.4.0
deprecation==1.0
dogpile.cache==0.6.2
extras==1.0.0

View File

@ -0,0 +1,6 @@
---
upgrade:
- |
Python 2.7 support has been dropped. Last release of python-saharaclient
to support python 2.7 is OpenStack Train. The minimum version of Python now
supported by python-saharaclient is Python 3.6.

View File

@ -14,8 +14,6 @@ classifier =
License :: OSI Approved :: Apache Software License
Operating System :: POSIX :: Linux
Programming Language :: Python
Programming Language :: Python :: 2
Programming Language :: Python :: 2.7
Programming Language :: Python :: 3
Programming Language :: Python :: 3.6
Programming Language :: Python :: 3.7

22
tox.ini
View File

@ -1,9 +1,13 @@
[tox]
envlist = py27,py37,pypy,pep8,releasenotes
minversion = 2.0
envlist = py37,pypy,pep8,releasenotes
minversioon = 3.1.1
skipsdist = True
# this allows tox to infer the base python from the environment name
# and override any basepython configured in this file
ignore_basepython_conflict = true
[testenv]
basepython = python3
usedevelop = True
install_command = pip install {opts} {packages}
setenv =
@ -23,16 +27,11 @@ passenv = http_proxy HTTP_PROXY https_proxy HTTPS_PROXY no_proxy NO_PROXY
basepython = python3
commands = oslo_debug_helper -t saharaclient/tests/unit {posargs}
[testenv:debug-py27]
basepython = python2.7
commands = oslo_debug_helper -t saharaclient/tests/unit {posargs}
[testenv:debug-py36]
basepython = python3.6
commands = oslo_debug_helper -t saharaclient/tests/unit {posargs}
[testenv:cover]
basepython = python3
setenv =
{[testenv]setenv}
PYTHON=coverage run --source saharaclient --parallel-mode
@ -45,16 +44,11 @@ commands =
coverage xml -o cover/coverage.xml
coverage report
[tox:jenkins]
sitepackages = False
[testenv:pep8]
basepython = python3
sitepackages = False
commands = flake8
[testenv:doc8]
basepython = python3
deps =
-c{env:UPPER_CONSTRAINTS_FILE:https://opendev.org/openstack/requirements/raw/branch/master/upper-constraints.txt}
-r{toxinidir}/requirements.txt
@ -63,11 +57,9 @@ deps =
commands = doc8 doc/source
[testenv:venv]
basepython = python3
commands = {posargs}
[testenv:docs]
basepython = python3
deps =
-c{env:UPPER_CONSTRAINTS_FILE:https://opendev.org/openstack/requirements/raw/branch/master/upper-constraints.txt}
-r{toxinidir}/requirements.txt
@ -77,7 +69,6 @@ commands =
sphinx-build -W -b html doc/source doc/build/html
[testenv:releasenotes]
basepython = python3
deps =
-c{env:UPPER_CONSTRAINTS_FILE:https://opendev.org/openstack/requirements/raw/branch/master/upper-constraints.txt}
-r{toxinidir}/requirements.txt
@ -95,7 +86,6 @@ exclude=.venv,.git,.tox,dist,doc,*lib/python*,*egg,tools
local-check-factory = saharaclient.tests.hacking.checks.factory
[testenv:lower-constraints]
basepython = python3
deps =
-c{toxinidir}/lower-constraints.txt
-r{toxinidir}/test-requirements.txt