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

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

hacking is ready with python 3 and ok to drop the
python 2.7 support.

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

Change-Id: I3ae88a4a11f3c552061eaeb7330d01c1f214bcc6
This commit is contained in:
Ghanshyam Mann 2020-02-03 12:52:19 -06:00
parent 172d34813d
commit 30154d65d7
5 changed files with 15 additions and 15 deletions

View File

@ -3,8 +3,8 @@
- publish-openstack-docs-pti - publish-openstack-docs-pti
- openstack-cover-jobs - openstack-cover-jobs
- openstack-lower-constraints-jobs - openstack-lower-constraints-jobs
- openstack-python-jobs - openstack-python35-jobs
- openstack-python3-train-jobs - openstack-python3-ussuri-jobs
- openstack-pypy-jobs-nonvoting - openstack-pypy-jobs-nonvoting
- release-notes-jobs-python3 - release-notes-jobs-python3
check: check:

View File

@ -1,4 +1,3 @@
sphinx>=1.8.0,<2.0.0;python_version=='2.7' # BSD sphinx>=1.8.0,!=2.1.0 # BSD
sphinx>=1.8.0,!=2.1.0;python_version>='3.4' # BSD
openstackdocstheme>=1.18.1 # Apache-2.0 openstackdocstheme>=1.18.1 # Apache-2.0
reno>=2.5.0 # Apache-2.0 reno>=2.5.0 # Apache-2.0

View File

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

View File

@ -6,6 +6,7 @@ summary = OpenStack Hacking Guideline Enforcement
description-file = description-file =
README.rst README.rst
home-page = https://docs.openstack.org/hacking/latest/ home-page = https://docs.openstack.org/hacking/latest/
python-requires = >=3.5
classifier = classifier =
Development Status :: 4 - Beta Development Status :: 4 - Beta
Environment :: Console Environment :: Console
@ -15,9 +16,8 @@ classifier =
License :: OSI Approved :: Apache Software License License :: OSI Approved :: Apache Software License
Operating System :: OS Independent Operating System :: OS Independent
Programming Language :: Python Programming Language :: Python
Programming Language :: Python :: 2
Programming Language :: Python :: 2.7
Programming Language :: Python :: 3 Programming Language :: Python :: 3
Programming Language :: Python :: 3.5
Programming Language :: Python :: 3.6 Programming Language :: Python :: 3.6
Programming Language :: Python :: 3.7 Programming Language :: Python :: 3.7

13
tox.ini
View File

@ -1,9 +1,11 @@
[tox] [tox]
minversion = 2.0 minversion = 3.1.1
skipsdist = True skipsdist = True
envlist = py27,py36,py37,pep8,pypy envlist = py36,py37,pep8,pypy
ignore_basepython_conflict = True
[testenv] [testenv]
basepython = python3
usedevelop = True usedevelop = True
install_command = pip install {opts} {packages} install_command = pip install {opts} {packages}
deps = deps =
@ -14,13 +16,11 @@ commands =
stestr run --slowest {posargs} stestr run --slowest {posargs}
[testenv:integration] [testenv:integration]
basepython = python3
whitelist_externals = bash whitelist_externals = bash
commands = commands =
bash integration-test/test.sh {posargs} bash integration-test/test.sh {posargs}
[testenv:cover] [testenv:cover]
basepython = python3
setenv = setenv =
PYTHON=coverage run --source hacking --parallel-mode PYTHON=coverage run --source hacking --parallel-mode
commands = commands =
@ -30,7 +30,6 @@ commands =
coverage xml -o cover/coverage.xml coverage xml -o cover/coverage.xml
[testenv:docs] [testenv:docs]
basepython = python3
deps = deps =
-c{env:UPPER_CONSTRAINTS_FILE:https://git.openstack.org/cgit/openstack/requirements/plain/upper-constraints.txt} -c{env:UPPER_CONSTRAINTS_FILE:https://git.openstack.org/cgit/openstack/requirements/plain/upper-constraints.txt}
-r{toxinidir}/doc/requirements.txt -r{toxinidir}/doc/requirements.txt
@ -38,18 +37,15 @@ commands =
sphinx-build -W -b html doc/source doc/build/html sphinx-build -W -b html doc/source doc/build/html
[testenv:releasenotes] [testenv:releasenotes]
basepython = python3
deps = deps =
{[testenv:docs]deps} {[testenv:docs]deps}
commands = commands =
sphinx-build -W -b html releasenotes/source releasenotes/build/html sphinx-build -W -b html releasenotes/source releasenotes/build/html
[testenv:venv] [testenv:venv]
basepython = python3
commands = {posargs} commands = {posargs}
[testenv:pep8] [testenv:pep8]
basepython = python3
commands = flake8 {posargs} commands = flake8 {posargs}
[flake8] [flake8]
@ -61,7 +57,6 @@ enable-extensions = H106
local-check = hacking.tests.test_local.check local-check = hacking.tests.test_local.check
[testenv:lower-constraints] [testenv:lower-constraints]
basepython = python3
deps = deps =
-c{toxinidir}/lower-constraints.txt -c{toxinidir}/lower-constraints.txt
-r{toxinidir}/test-requirements.txt -r{toxinidir}/test-requirements.txt