From da885db8bcce5d4cd9ffd1180ab2627fb2a78ec0 Mon Sep 17 00:00:00 2001 From: Andreas Jaeger Date: Sat, 4 Apr 2020 16:53:20 +0200 Subject: [PATCH] Cleanup py27 support Make a few cleanups: - Remove python 2.7 stanza from setup.py - Add requires on python >= 3.6 to setup.cfg so that pypi and pip know about the requirement - Remove obsolete sections from setup.cfg: * Wheel is not needed for python 3 only repo - Update classifiers - Update requirements, no need for python_version anymore - Remove html_last_updated_fmt from conf.py, this is not needed with openstackdocstheme anymore; update openstackdocstheme requirement Change-Id: I8811b249e53df8e25c46fe63d71b7dbb400dac19 --- doc/requirements.txt | 5 ++--- doc/source/conf.py | 1 - lower-constraints.txt | 2 +- setup.cfg | 6 +++--- setup.py | 9 --------- 5 files changed, 6 insertions(+), 17 deletions(-) diff --git a/doc/requirements.txt b/doc/requirements.txt index 711fb972..e6bf20b9 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,>=1.6.2;python_version>='3.4' # BSD -openstackdocstheme>=1.18.1 # Apache-2.0 +sphinx!=1.6.6,!=1.6.7,>=1.6.2 # BSD +openstackdocstheme>=1.32.1 # Apache-2.0 reno>=2.5.0 # Apache-2.0 diff --git a/doc/source/conf.py b/doc/source/conf.py index a2a02dba..15fd521b 100644 --- a/doc/source/conf.py +++ b/doc/source/conf.py @@ -65,7 +65,6 @@ html_theme = 'openstackdocs' repository_name = 'openstack/python-magnumclient' bug_project = 'python-magnumclient' bug_tag = '' -html_last_updated_fmt = '%Y-%m-%d %H:%M' # Output file base name for HTML help builder. diff --git a/lower-constraints.txt b/lower-constraints.txt index e989e565..a8da2e8c 100644 --- a/lower-constraints.txt +++ b/lower-constraints.txt @@ -47,7 +47,7 @@ msgpack-python==0.4.0 munch==2.1.0 netaddr==0.7.18 netifaces==0.10.4 -openstackdocstheme==1.18.1 +openstackdocstheme==1.32.1 openstacksdk==0.11.2 os-client-config==1.28.0 os-service-types==1.2.0 diff --git a/setup.cfg b/setup.cfg index fe3e0f8e..fa264812 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/python-magnumclient/latest/ +python-requires = >=3.6 classifier = Environment :: OpenStack Intended Audience :: Information Technology @@ -13,6 +14,8 @@ classifier = License :: OSI Approved :: Apache Software License Operating System :: POSIX :: Linux Programming Language :: Python + Programming Language :: Python :: Implementation :: CPython + Programming Language :: Python :: 3 :: Only Programming Language :: Python :: 2 Programming Language :: Python :: 3 Programming Language :: Python :: 3.6 @@ -75,6 +78,3 @@ input_file = magnumclient/locale/magnumclient.pot keywords = _ gettext ngettext l_ lazy_gettext mapping_file = babel.cfg output_file = magnumclient/locale/magnumclient.pot - -[wheel] -universal = 1 diff --git a/setup.py b/setup.py index 566d8443..cd35c3c3 100644 --- a/setup.py +++ b/setup.py @@ -13,17 +13,8 @@ # See the License for the specific language governing permissions and # limitations under the License. -# 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)