[ussuri][goal] Drop python 2.7 support and testing
OpenStack is dropping the py2.7 support in ussuri cycle. monasca-log-api 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 Depends-On: https://review.opendev.org/#/c/693631/ Change-Id: I3909027440b3af91d5c4fb964e862dedceaa6bed
This commit is contained in:
parent
673087bad1
commit
98f8469157
14
.zuul.yaml
14
.zuul.yaml
|
@ -50,19 +50,14 @@
|
||||||
c-vol: false
|
c-vol: false
|
||||||
cinder: false
|
cinder: false
|
||||||
horizon: false
|
horizon: false
|
||||||
|
devstack_localrc:
|
||||||
|
USE_PYTHON3: true
|
||||||
irrelevant-files:
|
irrelevant-files:
|
||||||
- ^.*\.rst$
|
- ^.*\.rst$
|
||||||
- ^.*\.md$
|
- ^.*\.md$
|
||||||
- ^doc/.*$
|
- ^doc/.*$
|
||||||
- ^releasenotes/.*$
|
- ^releasenotes/.*$
|
||||||
|
|
||||||
- job:
|
|
||||||
name: monascalog-python2-tempest
|
|
||||||
parent: monascalog-tempest-base
|
|
||||||
vars:
|
|
||||||
devstack_localrc:
|
|
||||||
TEMPEST_PLUGINS: /opt/stack/monasca-tempest-plugin
|
|
||||||
|
|
||||||
- job:
|
- job:
|
||||||
name: monascalog-python3-tempest
|
name: monascalog-python3-tempest
|
||||||
parent: monascalog-tempest-base
|
parent: monascalog-tempest-base
|
||||||
|
@ -76,19 +71,16 @@
|
||||||
- check-requirements
|
- check-requirements
|
||||||
- openstack-cover-jobs
|
- openstack-cover-jobs
|
||||||
- openstack-lower-constraints-jobs
|
- openstack-lower-constraints-jobs
|
||||||
- openstack-python-jobs
|
- openstack-python3-ussuri-jobs
|
||||||
- openstack-python3-train-jobs
|
|
||||||
- publish-openstack-docs-pti
|
- publish-openstack-docs-pti
|
||||||
- release-notes-jobs-python3
|
- release-notes-jobs-python3
|
||||||
check:
|
check:
|
||||||
jobs:
|
jobs:
|
||||||
- monascalog-python2-tempest
|
|
||||||
- monascalog-python3-tempest
|
- monascalog-python3-tempest
|
||||||
- build-monasca-docker-image
|
- build-monasca-docker-image
|
||||||
gate:
|
gate:
|
||||||
queue: monasca
|
queue: monasca
|
||||||
jobs:
|
jobs:
|
||||||
- monascalog-python2-tempest
|
|
||||||
- monascalog-python3-tempest
|
- monascalog-python3-tempest
|
||||||
post:
|
post:
|
||||||
jobs:
|
jobs:
|
||||||
|
|
|
@ -0,0 +1,6 @@
|
||||||
|
---
|
||||||
|
upgrade:
|
||||||
|
- |
|
||||||
|
Python 2.7 support has been dropped. Last release of monasca-log-api
|
||||||
|
to support python 2.7 is OpenStack Train. The minimum version of Python now
|
||||||
|
supported by monasca-log-api is Python 3.6.
|
|
@ -13,8 +13,6 @@ classifier =
|
||||||
License :: OSI Approved :: Apache Software License
|
License :: OSI Approved :: Apache Software License
|
||||||
Operating System :: POSIX :: Linux
|
Operating System :: POSIX :: Linux
|
||||||
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.6
|
Programming Language :: Python :: 3.6
|
||||||
Programming Language :: Python :: 3.7
|
Programming Language :: Python :: 3.7
|
||||||
|
|
|
@ -16,7 +16,6 @@ simplejson>=3.5.1 # MIT
|
||||||
|
|
||||||
# documentation
|
# documentation
|
||||||
doc8>=0.6.0 # Apache-2.0
|
doc8>=0.6.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,!=2.1.0,>=1.6.2;python_version>='3.4' # BSD
|
sphinx!=1.6.6,!=1.6.7,!=2.1.0,>=1.6.2;python_version>='3.4' # BSD
|
||||||
os-api-ref>=1.4.0 # Apache-2.0
|
os-api-ref>=1.4.0 # Apache-2.0
|
||||||
reno>=2.5.0 # Apache-2.0
|
reno>=2.5.0 # Apache-2.0
|
||||||
|
|
21
tox.ini
21
tox.ini
|
@ -1,9 +1,10 @@
|
||||||
[tox]
|
[tox]
|
||||||
envlist = py27,py37,pep8,cover
|
envlist = py37,pep8,cover
|
||||||
minversion = 2.7
|
minversion = 2.7
|
||||||
skipsdist = True
|
skipsdist = True
|
||||||
|
|
||||||
[testenv]
|
[testenv]
|
||||||
|
basepython = python3
|
||||||
usedevelop = True
|
usedevelop = True
|
||||||
setenv = VIRTUAL_ENV={envdir}
|
setenv = VIRTUAL_ENV={envdir}
|
||||||
OS_TEST_PATH=monasca_log_api/tests
|
OS_TEST_PATH=monasca_log_api/tests
|
||||||
|
@ -23,7 +24,6 @@ commands =
|
||||||
|
|
||||||
[testenv:cover]
|
[testenv:cover]
|
||||||
description = Calculates code coverage
|
description = Calculates code coverage
|
||||||
basepython = python3
|
|
||||||
setenv =
|
setenv =
|
||||||
PYTHON=coverage run --source monasca_log_api --parallel-mode
|
PYTHON=coverage run --source monasca_log_api --parallel-mode
|
||||||
commands =
|
commands =
|
||||||
|
@ -33,20 +33,17 @@ commands =
|
||||||
coverage xml -o cover/coverage.xml
|
coverage xml -o cover/coverage.xml
|
||||||
|
|
||||||
[testenv:debug]
|
[testenv:debug]
|
||||||
basepython = python3
|
|
||||||
description = Allows to run unit-test with debug mode enabled
|
description = Allows to run unit-test with debug mode enabled
|
||||||
commands =
|
commands =
|
||||||
oslo_debug_helper -t {toxinidir}/monasca_log_api/tests {posargs}
|
oslo_debug_helper -t {toxinidir}/monasca_log_api/tests {posargs}
|
||||||
|
|
||||||
[testenv:bashate]
|
[testenv:bashate]
|
||||||
basepython = python3
|
|
||||||
description = Validates (pep8-like) devstack plugins
|
description = Validates (pep8-like) devstack plugins
|
||||||
skip_install = True
|
skip_install = True
|
||||||
usedevelop = False
|
usedevelop = False
|
||||||
commands = bash {toxinidir}/tools/bashate.sh {toxinidir}/devstack
|
commands = bash {toxinidir}/tools/bashate.sh {toxinidir}/devstack
|
||||||
|
|
||||||
[testenv:bandit]
|
[testenv:bandit]
|
||||||
basepython = python3
|
|
||||||
description = Validates codebase with bandit
|
description = Validates codebase with bandit
|
||||||
skip_install = True
|
skip_install = True
|
||||||
usedevelop = False
|
usedevelop = False
|
||||||
|
@ -55,7 +52,6 @@ commands =
|
||||||
bandit -r monasca_log_api -n5 -s B101 -x monasca_log_api/tests
|
bandit -r monasca_log_api -n5 -s B101 -x monasca_log_api/tests
|
||||||
|
|
||||||
[testenv:pep8]
|
[testenv:pep8]
|
||||||
basepython = python3
|
|
||||||
description = Runs set of linters against codebase (flake8, bandit, bashate, checkniceness)
|
description = Runs set of linters against codebase (flake8, bandit, bashate, checkniceness)
|
||||||
commands =
|
commands =
|
||||||
{[testenv:flake8]commands}
|
{[testenv:flake8]commands}
|
||||||
|
@ -64,29 +60,24 @@ commands =
|
||||||
{[testenv:checkniceness]commands}
|
{[testenv:checkniceness]commands}
|
||||||
|
|
||||||
[testenv:flake8]
|
[testenv:flake8]
|
||||||
basepython = python3
|
|
||||||
description = Validates codebase with flake
|
description = Validates codebase with flake
|
||||||
commands =
|
commands =
|
||||||
flake8 monasca_log_api
|
flake8 monasca_log_api
|
||||||
|
|
||||||
[testenv:genconfig]
|
[testenv:genconfig]
|
||||||
basepython = python3
|
|
||||||
description = Generates sample documentation file for monasca-log-api
|
description = Generates sample documentation file for monasca-log-api
|
||||||
commands = oslo-config-generator --config-file=config-generator/monasca-log-api.conf
|
commands = oslo-config-generator --config-file=config-generator/monasca-log-api.conf
|
||||||
|
|
||||||
[testenv:genpolicy]
|
[testenv:genpolicy]
|
||||||
basepython = python3
|
|
||||||
description = Generates sample policy.json file for monasca-log-api
|
description = Generates sample policy.json file for monasca-log-api
|
||||||
commands = oslopolicy-sample-generator --config-file=config-generator/policy.conf
|
commands = oslopolicy-sample-generator --config-file=config-generator/policy.conf
|
||||||
|
|
||||||
[testenv:docs]
|
[testenv:docs]
|
||||||
basepython = python3
|
|
||||||
description = Builds main documention
|
description = Builds main documention
|
||||||
commands =
|
commands =
|
||||||
{[testenv:devdocs]commands}
|
{[testenv:devdocs]commands}
|
||||||
|
|
||||||
[testenv:api-guide]
|
[testenv:api-guide]
|
||||||
basepython = python3
|
|
||||||
description = Called from CI scripts to test and publish the API Guide
|
description = Called from CI scripts to test and publish the API Guide
|
||||||
commands =
|
commands =
|
||||||
rm -rf api-guide/build
|
rm -rf api-guide/build
|
||||||
|
@ -94,7 +85,6 @@ commands =
|
||||||
sphinx-build -W -b html -d api-guide/build/doctrees api-guide/source api-guide/build/html
|
sphinx-build -W -b html -d api-guide/build/doctrees api-guide/source api-guide/build/html
|
||||||
|
|
||||||
[testenv:api-ref]
|
[testenv:api-ref]
|
||||||
basepython = python3
|
|
||||||
description = Called from CI scripts to test and publish the API Ref
|
description = Called from CI scripts to test and publish the API Ref
|
||||||
commands =
|
commands =
|
||||||
rm -rf api-ref/build
|
rm -rf api-ref/build
|
||||||
|
@ -102,14 +92,12 @@ commands =
|
||||||
sphinx-build -W -b html -d api-ref/build/doctrees api-ref/source api-ref/build/html
|
sphinx-build -W -b html -d api-ref/build/doctrees api-ref/source api-ref/build/html
|
||||||
|
|
||||||
[testenv:releasenotes]
|
[testenv:releasenotes]
|
||||||
basepython = python3
|
|
||||||
description = Called from CI script to test and publish the Release Notes
|
description = Called from CI script to test and publish the Release Notes
|
||||||
commands =
|
commands =
|
||||||
rm -rf releasenotes/build
|
rm -rf releasenotes/build
|
||||||
sphinx-build -a -E -W -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html
|
sphinx-build -a -E -W -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html
|
||||||
|
|
||||||
[testenv:all-docs]
|
[testenv:all-docs]
|
||||||
basepython = python3
|
|
||||||
description = Builds all docouments
|
description = Builds all docouments
|
||||||
commands =
|
commands =
|
||||||
{[testenv:devdocs]commands}
|
{[testenv:devdocs]commands}
|
||||||
|
@ -118,7 +106,6 @@ commands =
|
||||||
{[testenv:releasenotes]commands}
|
{[testenv:releasenotes]commands}
|
||||||
|
|
||||||
[testenv:devdocs]
|
[testenv:devdocs]
|
||||||
basepython = python3
|
|
||||||
description = Builds developer documentation
|
description = Builds developer documentation
|
||||||
commands =
|
commands =
|
||||||
rm -rf doc/build
|
rm -rf doc/build
|
||||||
|
@ -127,7 +114,6 @@ commands =
|
||||||
python setup.py build_sphinx
|
python setup.py build_sphinx
|
||||||
|
|
||||||
[testenv:checkniceness]
|
[testenv:checkniceness]
|
||||||
basepython = python3
|
|
||||||
description = Validates (pep-like) documenation
|
description = Validates (pep-like) documenation
|
||||||
skip_install = True
|
skip_install = True
|
||||||
usedevelop = False
|
usedevelop = False
|
||||||
|
@ -138,7 +124,6 @@ commands =
|
||||||
doc8 --file-encoding utf-8 {toxinidir}/releasenotes
|
doc8 --file-encoding utf-8 {toxinidir}/releasenotes
|
||||||
|
|
||||||
[testenv:checkjson]
|
[testenv:checkjson]
|
||||||
basepython = python3
|
|
||||||
description = Validates all json samples inside doc folder
|
description = Validates all json samples inside doc folder
|
||||||
skip_install = True
|
skip_install = True
|
||||||
usedevelop = False
|
usedevelop = False
|
||||||
|
@ -153,7 +138,6 @@ commands =
|
||||||
bash -c '! find doc/ -type f -name *.json | xargs -t -n1 python -m json.tool 2>&1 > /dev/null | grep -B1 -v ^python'
|
bash -c '! find doc/ -type f -name *.json | xargs -t -n1 python -m json.tool 2>&1 > /dev/null | grep -B1 -v ^python'
|
||||||
|
|
||||||
[testenv:venv]
|
[testenv:venv]
|
||||||
basepython = python3
|
|
||||||
commands = {posargs}
|
commands = {posargs}
|
||||||
|
|
||||||
[flake8]
|
[flake8]
|
||||||
|
@ -167,7 +151,6 @@ import_exceptions =
|
||||||
six.moves
|
six.moves
|
||||||
|
|
||||||
[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
|
||||||
|
|
Loading…
Reference in New Issue