Browse Source

Drop python 2.7 support and testing

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

python-ironicclient 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: Iacc50fde00f0d24e9c6ee2b1ac61b8fa060094fb
changes/40/695540/3
Iury Gregory Melo Ferreira 1 year ago
parent
commit
f51566545e
8 changed files with 11 additions and 49 deletions
  1. +1
    -1
      .gitignore
  2. +0
    -1
      doc/requirements.txt
  3. +2
    -7
      playbooks/functional/run.yaml
  4. +6
    -0
      releasenotes/notes/drop-py-2-7-b0b950c0c2b6a667.yaml
  5. +0
    -2
      setup.cfg
  6. +2
    -15
      tox.ini
  7. +0
    -18
      zuul.d/ironicclient-jobs.yaml
  8. +0
    -5
      zuul.d/project.yaml

+ 1
- 1
.gitignore View File

@ -6,7 +6,7 @@
# Sphinx
_build
doc/source/api/
doc/source/reference/api/
# Release notes
releasenotes/build


+ 0
- 1
doc/requirements.txt View File

@ -3,6 +3,5 @@
# process, which may cause wedges in the gate later.
openstackdocstheme>=1.20.0 # Apache-2.0
reno>=2.5.0 # Apache-2.0
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
sphinxcontrib-apidoc>=0.2.0 # BSD

+ 2
- 7
playbooks/functional/run.yaml View File

@ -44,12 +44,7 @@
export IRONICCLIENT_TEST_CONFIG=$CONFIG_FILE
cd $IRONICCLIENT_DIR
if [[ $USE_PYTHON3 == "True" ]]; then
echo 'Running Functional Tests under Python3'
tox -e functionalpy3
else
echo 'Running Functional Tests under Python2'
tox -e functional
fi
echo 'Running Functional Tests under Python3'
tox -e functionalpy3
executable: /bin/bash
chdir: '/opt/stack/python-ironicclient'

+ 6
- 0
releasenotes/notes/drop-py-2-7-b0b950c0c2b6a667.yaml View File

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

+ 0
- 2
setup.cfg View File

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


+ 2
- 15
tox.ini View File

@ -1,9 +1,10 @@
[tox]
minversion = 2.0
envlist = py3,py27,pep8,pypy
envlist = py3,pep8,pypy
skipsdist = True
[testenv]
basepython = python3
setenv = VIRTUAL_ENV={envdir}
PYTHONDONTWRITEBYTECODE = 1
LANGUAGE=en_US
@ -19,7 +20,6 @@ commands =
stestr run {posargs}
[testenv:releasenotes]
basepython = python3
deps =
-c{env:UPPER_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
-r{toxinidir}/requirements.txt
@ -27,13 +27,11 @@ deps =
commands = sphinx-build -a -E -W -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html
[testenv:pep8]
basepython = python3
commands =
flake8 {posargs}
doc8 doc/source CONTRIBUTING.rst README.rst
[testenv:cover]
basepython = python3
setenv = {[testenv]setenv}
PYTHON=coverage run --source ironicclient --omit='*tests*' --parallel-mode
commands =
@ -44,7 +42,6 @@ commands =
coverage html -d ./cover --omit='*tests*'
[testenv:venv]
basepython = python3
deps =
-c{env:UPPER_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
-r{toxinidir}/test-requirements.txt
@ -52,21 +49,13 @@ deps =
-r{toxinidir}/doc/requirements.txt
commands = {posargs}
[testenv:functional]
passenv = *
setenv = TESTS_DIR=./ironicclient/tests/functional
LANGUAGE=en_US
OS_TESTENV_NAME = {envname}
[testenv:functionalpy3]
basepython = python3
passenv = *
setenv = TESTS_DIR=./ironicclient/tests/functional
LANGUAGE=en_US
OS_TESTENV_NAME = {envname}
[testenv:docs]
basepython = python3
deps =
-c{env:UPPER_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
-r{toxinidir}/requirements.txt
@ -75,7 +64,6 @@ commands =
sphinx-build -W -b html doc/source doc/build/html
[testenv:pdf-docs]
basepython = python3
whitelist_externals = make
deps = {[testenv:docs]deps}
commands =
@ -97,7 +85,6 @@ enable-extensions=H106,H203,H204,H205,H210,H904
import_exceptions = testtools.matchers, ironicclient.common.i18n
[testenv:lower-constraints]
basepython = python3
deps =
-c{toxinidir}/lower-constraints.txt
-r{toxinidir}/test-requirements.txt


+ 0
- 18
zuul.d/ironicclient-jobs.yaml View File

@ -35,16 +35,6 @@
mysql: True
rabbit: True
# NOTE(iurygregory): drop when the time comes
- job:
name: ironicclient-functional-python2
parent: ironicclient-functional
post-run: playbooks/functional/run.yaml
vars:
tox_envlist: functional
devstack_localrc:
USE_PYTHON3: False
- job:
name: ironicclient-tempest
parent: ironic-base
@ -54,11 +44,3 @@
vars:
devstack_localrc:
EBTABLES_RACE_FIX: True
# NOTE(iurygregory): drop when the time comes
- job:
name: ironicclient-tempest-python2
parent: ironicclient-tempest
vars:
devstack_localrc:
USE_PYTHON3: False

+ 0
- 5
zuul.d/project.yaml View File

@ -3,7 +3,6 @@
- check-requirements
- openstack-cover-jobs
- openstack-lower-constraints-jobs
- openstack-python-jobs
- openstack-python3-ussuri-jobs
- openstackclient-plugin-jobs
- publish-openstack-docs-pti
@ -11,13 +10,9 @@
check:
jobs:
- ironicclient-functional
- ironicclient-functional-python2
- ironicclient-tempest
- ironicclient-tempest-python2
gate:
queue: ironic
jobs:
- ironicclient-functional
- ironicclient-functional-python2
- ironicclient-tempest
- ironicclient-tempest-python2

Loading…
Cancel
Save