diff --git a/.zuul.yaml b/.zuul.yaml index 3d3287df..afe8fec3 100644 --- a/.zuul.yaml +++ b/.zuul.yaml @@ -27,7 +27,6 @@ - horizon-nodejs10-jobs - horizon-non-primary-django-jobs - openstack-lower-constraints-jobs - - openstack-python-jobs - openstack-python3-ussuri-jobs - publish-openstack-docs-pti - release-notes-jobs-python3 diff --git a/doc/requirements.txt b/doc/requirements.txt index 93bb154d..10101c2f 100644 --- a/doc/requirements.txt +++ b/doc/requirements.txt @@ -1,4 +1,3 @@ -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 openstackdocstheme>=1.20.0 # Apache-2.0 reno>=2.5.0 # Apache-2.0 diff --git a/ironic_ui/karma.conf.js b/ironic_ui/karma.conf.js index 67037090..b784757d 100644 --- a/ironic_ui/karma.conf.js +++ b/ironic_ui/karma.conf.js @@ -17,7 +17,7 @@ module.exports = function (config) { // This tox venv is setup in the post-install npm step - var toxPath = '../.tox/py27/lib/python2.7/site-packages/'; + var toxPath = '../.tox/py36/lib/python3.6/site-packages/'; config.set({ preprocessors: { diff --git a/manage.py b/manage.py index b9e0f36e..1a13c6f1 100755 --- a/manage.py +++ b/manage.py @@ -1,4 +1,4 @@ -#!/usr/bin/env python +#!/usr/bin/env python3 # Copyright 2016 Cisco Systems, Inc. # diff --git a/package.json b/package.json index 4926a0cd..0e45a548 100644 --- a/package.json +++ b/package.json @@ -24,7 +24,7 @@ "karma-threshold-reporter": "^0.1.15" }, "scripts": { - "postinstall": "if [ ! -d .tox ] || [ ! -d .tox/py27 ]; then tox -epy27 --notest; fi", + "postinstall": "if [ ! -d .tox ] || [ ! -d .tox/py36 ]; then tox -epy36 --notest; fi", "test": "karma start ironic_ui/karma.conf.js --single-run", "lint": "eslint --no-color ironic_ui/static", "lintq": "eslint --quiet ironic_ui/static" diff --git a/releasenotes/notes/drop-python2-0bf548c3946068af.yaml b/releasenotes/notes/drop-python2-0bf548c3946068af.yaml new file mode 100644 index 00000000..065dcf16 --- /dev/null +++ b/releasenotes/notes/drop-python2-0bf548c3946068af.yaml @@ -0,0 +1,6 @@ +--- +upgrade: + - | + Python 2.7 support has been dropped. Last release of ironic-ui to + support Python 2.7 is OpenStack Train. The minimum version of Python + now supported by ironic-ui is Python 3.6. diff --git a/setup.cfg b/setup.cfg index a9a70ae8..fa07fa33 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 b115f591..f17ccab2 100644 --- a/tox.ini +++ b/tox.ini @@ -1,11 +1,12 @@ [tox] minversion = 1.8 skipsdist = True -envlist = py3,py27,py3-{dj111,dj22},pep8 +envlist = py3,py3-{dj111,dj22},pep8 [testenv] usedevelop = True install_command = pip install -c{env:UPPER_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master} {opts} {packages} +basepython = python3 setenv = VIRTUAL_ENV={envdir} NOSE_WITH_OPENSTACK=1 NOSE_OPENSTACK_COLOR=1 @@ -28,30 +29,24 @@ setenv = INTEGRATION_TESTS=1 SELENIUM_HEADLESS=1 HORIZON_INTEGRATION_TESTS_CONFIG_FILE=ironic_ui/test/integration/horizon.conf -basepython = python3 commands = python manage.py test ironic_ui.test.integration --settings=ironic_ui.test.settings --tag integration [testenv:pep8] -basepython = python3 commands = flake8 {posargs} [testenv:venv] -basepython = python3 commands = {posargs} [testenv:py3-dev] -basepython = python3 commands = pip install {env:HORIZON_REPO:git+https://opendev.org/openstack/horizon} {[testenv]commands} [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}/doc/requirements.txt @@ -59,7 +54,6 @@ commands = sphinx-build -W -b html doc/source doc/build/html [testenv:pdf-docs] -basepython = python3 deps = {[testenv:docs]deps} whitelist_externals = make commands = @@ -67,7 +61,6 @@ commands = make -C doc/build/pdf [testenv:debug] -basepython = python3 commands = oslo_debug_helper -t ironic_ui/test/tests {posargs} [flake8] @@ -77,14 +70,12 @@ builtins = _ exclude=.venv,.git,.tox,dist,doc,*lib/python*,*egg,build [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 -W -E -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html [testenv:extractmessages] -basepython = python3 commands = pybabel extract -F babel-django.cfg \ -o ironic_ui/locale/django.pot -k gettext_noop -k gettext_lazy -k ngettext_lazy:1,2 \ @@ -98,7 +89,6 @@ commands = [testenv:lower-constraints] -basepython = python3 deps = -c{toxinidir}/lower-constraints.txt -r{toxinidir}/test-requirements.txt