diff --git a/.zuul.yaml b/.zuul.yaml index bd1562491f..3a89ee776d 100644 --- a/.zuul.yaml +++ b/.zuul.yaml @@ -3,8 +3,7 @@ - check-requirements - openstack-cover-jobs - openstack-lower-constraints-jobs - - openstack-python-jobs - - openstack-python3-train-jobs + - openstack-python3-ussuri-jobs - periodic-stable-jobs - publish-openstack-docs-pti - release-notes-jobs-python3 @@ -113,6 +112,7 @@ SERVICE_HOST: '' HOST_IP: '' VNCSERVER_PROXYCLIENT_ADDRESS: 127.0.0.1 + USE_PYTHON3: True run: playbooks/trove-devstack-base.yaml irrelevant-files: - ^.*\.rst$ @@ -125,7 +125,7 @@ - job: name: trove-fakemodetests-base - parent: openstack-tox-py27 + parent: openstack-tox-py36 abstract: true irrelevant-files: - ^.*\.rst$ @@ -382,4 +382,4 @@ guest_os_release: xenial guest_username: ubuntu branch: master - dev_mode: true \ No newline at end of file + dev_mode: true diff --git a/playbooks/legacy/grenade-dsvm-trove/run.yaml b/playbooks/legacy/grenade-dsvm-trove/run.yaml index ea0eea9c4e..1cf2a67e75 100644 --- a/playbooks/legacy/grenade-dsvm-trove/run.yaml +++ b/playbooks/legacy/grenade-dsvm-trove/run.yaml @@ -36,6 +36,7 @@ export DEVSTACK_GATE_TROVE=1 export TEMPEST_CONCURRENCY=2 export BRANCH_OVERRIDE=default + export DEVSTACK_GATE_USE_PYTHON3=True if [ "$BRANCH_OVERRIDE" != "default" ] ; then export OVERRIDE_ZUUL_BRANCH=$BRANCH_OVERRIDE fi diff --git a/releasenotes/notes/drop-py-2-7-010fe6df0c10352d.yaml b/releasenotes/notes/drop-py-2-7-010fe6df0c10352d.yaml new file mode 100644 index 0000000000..c887b9313d --- /dev/null +++ b/releasenotes/notes/drop-py-2-7-010fe6df0c10352d.yaml @@ -0,0 +1,6 @@ +--- +upgrade: + - | + Python 2.7 support has been dropped. Last release of Trove + to support py2.7 is OpenStack Train. The minimum version of Python now + supported by Trove is Python 3.6. diff --git a/requirements.txt b/requirements.txt index 35bddbc9ce..8c85b838ed 100644 --- a/requirements.txt +++ b/requirements.txt @@ -43,7 +43,6 @@ oslo.messaging>=5.29.0 # Apache-2.0 osprofiler>=1.4.0 # Apache-2.0 oslo.log>=3.36.0 # Apache-2.0 oslo.db>=4.27.0 # Apache-2.0 -enum34>=1.0.4;python_version=='2.7' or python_version=='2.6' or python_version=='3.3' # BSD xmltodict>=0.10.1 # MIT cryptography>=2.1.4 # BSD/Apache-2.0 oslo.policy>=1.30.0 # Apache-2.0 diff --git a/setup.cfg b/setup.cfg index a6055554e4..f031fbbcf3 100644 --- a/setup.cfg +++ b/setup.cfg @@ -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 diff --git a/tox.ini b/tox.ini index f36ce4a354..a5be1b39dc 100644 --- a/tox.ini +++ b/tox.ini @@ -1,9 +1,10 @@ [tox] -envlist = py27,py37,pep8,cover,api-ref,releasenotes,bandit,fakemodetests,pylint +envlist = py37,pep8,cover,api-ref,releasenotes,bandit,fakemodetests,pylint minversion = 2.0 skipsdist = True [testenv] +basepython = python3 setenv = VIRTUAL_ENV={envdir} PYTHONWARNINGS=default::DeprecationWarning OS_TEST_PATH=./trove/tests/unittests @@ -29,21 +30,17 @@ whitelist_externals = find sitepackages = True [testenv:pep8] -basepython = python3 commands = flake8 doc8 {posargs} [testenv:fakemodetests] -basepython = python3 commands = {envpython} run_tests.py [testenv:debug] -basepython = python3 commands = oslo_debug_helper {posargs} [testenv:cover] -basepython = python3 setenv = {[testenv]setenv} PYTHON=coverage run --source trove @@ -56,7 +53,6 @@ commands = coverage report [testenv:venv] -basepython = python3 commands = {posargs} [doc8] @@ -79,7 +75,6 @@ import_exceptions = trove.common.i18n local-check-factory = trove.hacking.checks.factory [testenv:api-ref] -basepython = python3 # This environment is called from CI scripts to test and publish # the API Ref to developer.openstack.org. commands = @@ -87,41 +82,33 @@ commands = sphinx-build -W -b html -d api-ref/build/doctrees api-ref/source api-ref/build/html [testenv:releasenotes] -basepython = python3 commands = sphinx-build -a -E -W -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html [testenv:bandit] -basepython = python3 commands = bandit -r trove -n5 -x tests [testenv:bandit-baseline] -basepython = python3 envdir = {toxworkdir}/bandit commands = bandit-baseline -r trove -n5 -x tests -ii -ll [testenv:genpolicy] -basepython = python3 commands = oslopolicy-sample-generator --config-file=tools/trove-policy-generator.conf [testenv:pylint] -basepython = python3 deps = -r{toxinidir}/requirements.txt -r{toxinidir}/test-requirements.txt commands = python tools/trove-pylint.py {posargs:check} [testenv:docs] -basepython = python3 commands = sphinx-build -W -b html doc/source doc/build/html [testenv:lower-constraints] -basepython = python3 deps = -c{toxinidir}/lower-constraints.txt -r{toxinidir}/test-requirements.txt -r{toxinidir}/requirements.txt [testenv:trovestack] -basepython = python3 skip_install = True changedir = {toxinidir}/integration/scripts passenv = *