Merge "Drop Python 2 Support"

This commit is contained in:
Zuul 2020-01-24 00:10:26 +00:00 committed by Gerrit Code Review
commit d9ac7173f1
5 changed files with 11 additions and 21 deletions

View File

@ -3,7 +3,6 @@
- check-requirements
- openstack-cover-jobs-neutron
- openstack-lower-constraints-jobs-neutron
- openstack-python-jobs-neutron
- openstack-python3-ussuri-jobs-neutron
- periodic-stable-jobs-neutron
- publish-openstack-docs-pti

View File

@ -1,8 +1,7 @@
# The order of packages is significant, because pip processes them in the order
# of appearance. Changing the order has an impact on the overall integration
# process, which may cause wedges in the gate later.
sphinx!=1.6.6,!=1.6.7,>=1.6.2,<2.0.0;python_version=='2.7' # BSD
sphinx!=1.6.6,!=1.6.7,>=1.6.2;python_version>='3.4' # BSD
sphinx!=1.6.6,!=1.6.7,>=1.6.2 # BSD
sphinxcontrib-apidoc>=0.2.0 # BSD
sphinxmark>=0.1.14 # Apache-2.0
openstackdocstheme>=1.18.1 # Apache-2.0

View File

@ -0,0 +1,5 @@
---
upgrade:
- |
Python 2.7 support has been dropped. The minimum version of Python now
supported by neutron-fwaas is Python 3.6.

View File

@ -6,6 +6,7 @@ description-file =
author = OpenStack
author-email = openstack-discuss@lists.openstack.org
home-page = https://docs.openstack.org/neutron-fwaas/latest/
python-requires = >=3.6
classifier =
Environment :: OpenStack
Intended Audience :: Information Technology
@ -16,6 +17,7 @@ classifier =
Programming Language :: Python :: 3
Programming Language :: Python :: 3.6
Programming Language :: Python :: 3.7
Programming Language :: Python :: 3 :: Only
[files]
packages =

21
tox.ini
View File

@ -1,9 +1,10 @@
[tox]
envlist = py27,py37,pep8,pylint
minversion = 2.0
envlist = py37,pep8,pylint
minversion = 3.1.1
skipsdist = True
[testenv]
basepython = python3
setenv = VIRTUAL_ENV={envdir}
PYTHONWARNINGS=default::DeprecationWarning
OS_LOG_CAPTURE={env:OS_LOG_CAPTURE:true}
@ -27,7 +28,6 @@ setenv = OS_TEST_TIMEOUT=180
commands = false
[testenv:dsvm]
basepython = python3
# Fake job to define environment variables shared between dsvm jobs
setenv = OS_SUDO_TESTING=1
OS_ROOTWRAP_CMD=sudo {envdir}/bin/neutron-rootwrap {envdir}/etc/neutron/rootwrap.conf
@ -37,7 +37,6 @@ setenv = OS_SUDO_TESTING=1
commands = false
[testenv:functional]
basepython = python3
setenv = {[testenv]setenv}
{[testenv:common]setenv}
OS_TEST_PATH=./neutron_fwaas/tests/functional
@ -46,7 +45,6 @@ commands =
stestr run {posargs}
[testenv:dsvm-fullstack]
basepython = python3
setenv = {[testenv]setenv}
{[testenv:common]setenv}
{[testenv:dsvm]setenv}
@ -60,7 +58,6 @@ commands =
[testenv:api]
basepython = python3
sitepackages=True
setenv =
OS_TEST_PATH=./neutron_fwaas/tests/tempest_plugin/tests/api/
@ -70,7 +67,6 @@ commands =
stestr run {posargs}
[testenv:scenario]
basepython = python3
sitepackages=True
setenv =
OS_TEST_PATH=./neutron_fwaas/tests/tempest_plugin/tests/scenario/
@ -80,7 +76,6 @@ commands =
stestr run {posargs}
[testenv:dsvm-functional]
basepython = python3
setenv =
OS_TEST_PATH=./neutron_fwaas/tests/functional
OS_SUDO_TESTING=1
@ -97,12 +92,10 @@ commands =
stestr run {posargs}
[testenv:releasenotes]
basepython = python3
deps = -r{toxinidir}/doc/requirements.txt
commands = sphinx-build -a -E -W -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html
[testenv:pep8]
basepython = python3
commands =
flake8
doc8 {posargs}
@ -113,7 +106,6 @@ commands =
whitelist_externals = sh
[testenv:cover]
basepython = python3
setenv = VIRTUAL_ENV={envdir}
LANGUAGE=en_US
PYTHON=coverage run --source neutron_fwaas --omit='*tests*' --parallel-mode
@ -126,12 +118,10 @@ commands =
coverage xml -o cover/coverage.xml
[testenv:venv]
basepython = python3
commands = {posargs}
deps = -r{toxinidir}/doc/requirements.txt
[testenv:docs]
basepython = python3
deps = -r{toxinidir}/doc/requirements.txt
whitelist_externals =
rm
@ -140,7 +130,6 @@ commands =
sphinx-build -W -b html doc/source doc/build/html
[testenv:pdf-docs]
basepython = python3
envdir = {toxworkdir}/docs
deps = {[testenv:docs]deps}
whitelist_externals =
@ -182,7 +171,6 @@ exclude = .venv,.git,.tox,dist,doc,*lib/python*,.tmp,*egg,build,tools,.ropeproje
import-order-style = pep8
[testenv:pylint]
basepython = python3
deps =
{[testenv]deps}
pylint
@ -194,14 +182,12 @@ import_exceptions = neutron_fwaas._i18n
local-check-factory = neutron_lib.hacking.checks.factory
[testenv:genconfig]
basepython = python3
commands = {toxinidir}/tools/generate_config_file_samples.sh
[testenv:genpolicy]
commands = oslopolicy-sample-generator --config-file=etc/oslo-policy-generator/policy.conf
[testenv:lower-constraints]
basepython = python3
deps =
-c{toxinidir}/lower-constraints.txt
-r{toxinidir}/test-requirements.txt
@ -214,7 +200,6 @@ commands =
pip install -q -e "git+https://git.openstack.org/openstack/neutron#egg=neutron"
[testenv:py3-dev]
basepython = python3
commands =
{[testenv:dev]commands}
{[testenv]commands}