Drop python 2.7 support and testing

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

Bifrost 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://review.opendev.org/#/c/691178/

Change-Id: Ia175fc588f283e33efe2961f006c35c4ecc255b1
This commit is contained in:
Madhuri Kumari 2019-11-23 18:59:01 +05:30 committed by Andreas Jaeger
parent 669a57a36d
commit 76c915aca2
4 changed files with 9 additions and 17 deletions

View File

@ -1,5 +1,4 @@
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,!=2.1.0,>=1.6.2;python_version>='3.4' # BSD
sphinx!=1.6.6,!=1.6.7,!=2.1.0,>=1.6.2 # BSD
sphinxcontrib-httpdomain>=1.3.0 # BSD
sphinxcontrib-blockdiag>=1.5.4 # BSD
sphinxcontrib-svg2pdfconverter>=0.1.0 # BSD

View File

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

View File

@ -13,8 +13,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

15
tox.ini
View File

@ -1,12 +1,13 @@
[tox]
minversion = 3.1.0
envlist = py3,py27,docs,pep8
envlist = py3,docs,pep8
skipsdist = True
ignore_basepython_conflict=true
[testenv]
usedevelop = True
install_command = pip install -U -c{env:UPPER_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master} {opts} {packages}
basepython = python3
setenv =
VIRTUAL_ENV={envdir}
PYTHONWARNINGS=default::DeprecationWarning
@ -16,23 +17,19 @@ commands = python setup.py test --slowest --testr-args='{posargs}'
passenv = http_proxy HTTP_PROXY https_proxy HTTPS_PROXY no_proxy NO_PROXY
[testenv:pep8]
basepython = python3
commands = flake8
doc8 doc/source releasenotes/source README.rst CONTRIBUTING.rst MISSION.rst HACKING.rst
[testenv:venv]
basepython = python3
deps =
-r{toxinidir}/test-requirements.txt
-r{toxinidir}/doc/requirements.txt
commands = {posargs}
[testenv:cover]
basepython = python3
commands = python setup.py test --coverage --testr-args='{posargs}'
[testenv:docs]
basepython = python3
deps =
-c{env:UPPER_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
-r{toxinidir}/requirements.txt
@ -40,27 +37,20 @@ deps =
commands = sphinx-build -W -b html doc/source doc/build/html
[testenv:pdf-docs]
basepython = python3
whitelist_externals = make
deps = {[testenv:docs]deps}
commands = sphinx-build -W -b latex doc/source doc/build/pdf
make -C doc/build/pdf
[testenv:debug]
basepython = python3
commands = oslo_debug_helper -t bifrost/tests {posargs}
[testenv:releasenotes]
basepython = python3
deps =
-c{env:UPPER_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
-r{toxinidir}/doc/requirements.txt
commands = sphinx-build -a -E -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html
[testenv:debug-py27]
basepython = python2.7
commands = oslo_debug_helper -t bifrost/tests {posargs}
[testenv:debug-py36]
basepython = python3.6
commands = oslo_debug_helper -t bifrost/tests {posargs}
@ -71,7 +61,6 @@ ignore = F403,H102,H303
exclude=.venv,.git,.tox,dist,doc,*lib/python*,*egg,build,os_ironic.py,os_ironic_node.py,os_ironic_inspect.py,os_keystone_service.py
[testenv:lower-constraints]
basepython = python3
deps =
-c{toxinidir}/lower-constraints.txt
-r{toxinidir}/test-requirements.txt