From 1fe4f029157ec6bdf67ceeb6de5af05c46fbd4fa Mon Sep 17 00:00:00 2001 From: Andreas Jaeger Date: Wed, 5 Feb 2020 19:37:19 +0100 Subject: [PATCH] [ussuri][goal] Drop python 2.7 support and testing OpenStack is dropping the py2.7 support in ussuri cycle. 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 Remove cruft from setup.cfg. Change-Id: Ic719c1f15120b68de97f0e20702b03baeb02f5e9 --- .../notes/drop-python-2-7-73d3113c69d724d6.yaml | 5 +++++ setup.cfg | 15 +++++---------- setup.py | 8 -------- tox.ini | 16 +++------------- 4 files changed, 13 insertions(+), 31 deletions(-) create mode 100644 releasenotes/notes/drop-python-2-7-73d3113c69d724d6.yaml diff --git a/releasenotes/notes/drop-python-2-7-73d3113c69d724d6.yaml b/releasenotes/notes/drop-python-2-7-73d3113c69d724d6.yaml new file mode 100644 index 00000000..f1cfe360 --- /dev/null +++ b/releasenotes/notes/drop-python-2-7-73d3113c69d724d6.yaml @@ -0,0 +1,5 @@ +--- +upgrade: + - | + Python 2.7 support has been dropped. The minimum version of Python now + supported by openstackdocstheme is Python 3.6. diff --git a/setup.cfg b/setup.cfg index 46b851ca..a6092ca2 100644 --- a/setup.cfg +++ b/setup.cfg @@ -6,6 +6,7 @@ description-file = author = OpenStack author-email = openstack-discuss@lists.openstack.org home-page = https://docs.openstack.org/openstackdocstheme/latest/ +python-requires = >=3.6 classifier = Environment :: OpenStack Intended Audience :: Information Technology @@ -13,16 +14,13 @@ 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.5 + Programming Language :: Python :: 3.6 + Programming Language :: Python :: 3.7 + Programming Language :: Python :: 3 :: Only + Programming Language :: Python :: Implementation :: CPython Topic :: Documentation -[global] -setup-hooks = - pbr.hooks.setup_hook - [files] packages = openstackdocstheme @@ -30,6 +28,3 @@ scripts = bin/docstheme-build-translated.sh bin/docstheme-lang-display-name.py bin/docstheme-build-pdf - -[wheel] -universal = 1 diff --git a/setup.py b/setup.py index 566d8443..f63cc23c 100644 --- a/setup.py +++ b/setup.py @@ -16,14 +16,6 @@ # THIS FILE IS MANAGED BY THE GLOBAL REQUIREMENTS REPO - DO NOT EDIT import setuptools -# In python < 2.7.4, a lazy loading of package `pbr` will break -# setuptools if some other modules registered functions in `atexit`. -# solution from: http://bugs.python.org/issue15881#msg170215 -try: - import multiprocessing # noqa -except ImportError: - pass - setuptools.setup( setup_requires=['pbr>=2.0.0'], pbr=True) diff --git a/tox.ini b/tox.ini index 4bbd5a9a..2806179f 100644 --- a/tox.ini +++ b/tox.ini @@ -1,10 +1,11 @@ [tox] -minversion = 2.0 +minversion = 3.1.0 envlist = pep8 +ignore_basepython_conflict = true [testenv] +basepython = python3 usedevelop = False -install_command = pip install {opts} {packages} deps = -c{env:UPPER_CONSTRAINTS_FILE:https://opendev.org/openstack/requirements/raw/upper-constraints.txt} -r{toxinidir}/test-requirements.txt @@ -16,22 +17,18 @@ whitelist_externals = make [testenv:pep8] -basepython = python3 commands = flake8 openstackdocstheme [testenv:venv] -basepython = python3 commands = {posargs} [testenv:docs] -basepython = python3 commands = rm -rf doc/build/html doc/build/doctrees sphinx-build -a -E -W -d doc/build/doctrees -b html doc/source doc/build/html [testenv:docs-starlingxdocs] -basepython = python3 envdir = {toxworkdir}/docs commands = rm -rf doc/build/html doc/build/doctrees @@ -44,31 +41,26 @@ commands = sphinx-build -a -E -W -d api-ref/build/doctrees -b html api-ref/source api-ref/build/html [testenv:releasenotes] -basepython = python3 commands = rm -rf releasenotes/build sphinx-build -a -E -W -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html [testenv:releasenotes-starlingxdocs] -basepython = python3 commands = rm -rf releasenotes/build sphinx-build -a -E -W -d releasenotes/build/doctrees -b html -D html_theme=starlingxdocs releasenotes/source releasenotes/build/html [testenv:api-ref] -basepython = python3 commands = rm -rf api-ref/build sphinx-build -a -E -W -d api-ref/build/doctrees -b html api-ref/source api-ref/build/html [testenv:api-ref-starlingxdocs] -basepython = python3 commands = rm -rf api-ref/build sphinx-build -a -E -W -d api-ref/build/doctrees -b html -D html_theme=starlingxdocs api-ref/source api-ref/build/html [testenv:pdf-docs] -basepython = python3 envdir = {toxworkdir}/docs commands = rm -rf doc/build/pdf @@ -76,7 +68,6 @@ commands = make -C doc/build/pdf [testenv:pdf-docs-starlingxdocs] -basepython = python3 envdir = {toxworkdir}/docs commands = rm -rf doc/build/pdf @@ -88,7 +79,6 @@ commands = # system dependencies are missing, since it's used to tell you what system # dependencies are missing! This also means that bindep must be installed # separately, outside of the requirements files. -basepython = python3 deps = bindep commands = bindep test