From 9004a32d33d236d09e45ef5fcc3c412b6705b321 Mon Sep 17 00:00:00 2001 From: Andreas Jaeger Date: Sat, 4 Apr 2020 11:26:15 +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 requirements, no need for python_version anymore - Remove old variables from conf.py, update openstackdocstheme requirement. - Remove hacking and friends from lower-constraints, they are not needed in installed system. Change-Id: I179d61545169f3d329c746c88dd4d38035d4075d --- doc/requirements.txt | 4 ++-- doc/source/conf.py | 10 ---------- lower-constraints.txt | 7 +------ requirements.txt | 1 - setup.cfg | 9 +-------- setup.py | 9 --------- 6 files changed, 4 insertions(+), 36 deletions(-) diff --git a/doc/requirements.txt b/doc/requirements.txt index 257ce5cf1..7cd210dd7 100644 --- a/doc/requirements.txt +++ b/doc/requirements.txt @@ -1,7 +1,7 @@ # The order of packages is significant, because pip processes them in the order # of appearance. Changing the order has an impact on the overall integration # process, which may cause wedges in the gate later. -openstackdocstheme>=1.18.1 # Apache-2.0 -sphinx!=1.6.6,!=1.6.7,>=1.6.2,!=2.1.0;python_version>='3.4' # BSD +openstackdocstheme>=1.32.1 # Apache-2.0 +sphinx!=1.6.6,!=1.6.7,>=1.6.2,!=2.1.0 # BSD reno>=2.5.0 # Apache-2.0 sphinxcontrib-programoutput>=0.11 # BSD diff --git a/doc/source/conf.py b/doc/source/conf.py index f642def35..252a65fd6 100644 --- a/doc/source/conf.py +++ b/doc/source/conf.py @@ -46,15 +46,6 @@ master_doc = 'index' project = u'python-manilaclient' copyright = u'Rackspace, based on work by Jacob Kaplan-Moss' -# The version info for the project you're documenting, acts as replacement for -# |version| and |release|, also used in various other places throughout the -# built documents. -# -# The short X.Y version. -version = '2.6' -# The full version, including alpha/beta/rc tags. -release = '2.6.10' - # List of directories, relative to source directory, that shouldn't be searched # for source files. exclude_trees = [] @@ -80,7 +71,6 @@ html_theme_path = [openstackdocstheme.get_html_theme_path()] repository_name = 'openstack/python-manilaclient' bug_project = 'python-manilaclient' bug_tag = 'docs' -html_last_updated_fmt = '%Y-%m-%d %H:%M' # -- Options for LaTeX output ------------------------------------------------- diff --git a/lower-constraints.txt b/lower-constraints.txt index c1db33a52..3b7308aa9 100644 --- a/lower-constraints.txt +++ b/lower-constraints.txt @@ -17,9 +17,7 @@ dulwich==0.15.0 extras==1.0.0 fasteners==0.7.0 fixtures==3.0.0 -flake8==2.5.5 future==0.16.0 -hacking==0.12.0 idna==2.6 imagesize==0.7.1 ipaddress==1.0.17 @@ -32,14 +30,13 @@ jsonschema==2.6.0 keystoneauth1==3.4.0 linecache2==1.0.0 MarkupSafe==1.0 -mccabe==0.2.1 mock==2.0.0 monotonic==0.6 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 @@ -54,12 +51,10 @@ oslo.serialization==2.18.0 oslo.utils==3.33.0 paramiko==2.0.0 pbr==2.0.0 -pep8==1.5.7 positional==1.2.1 prettytable==0.7.1 pyasn1==0.1.8 pycparser==2.18 -pyflakes==0.8.1 Pygments==2.2.0 pyinotify==0.9.6 pyOpenSSL==17.1.0 diff --git a/requirements.txt b/requirements.txt index 91469e61e..d8d09fc31 100644 --- a/requirements.txt +++ b/requirements.txt @@ -5,7 +5,6 @@ # pbr should be first pbr!=2.1.0,>=2.0.0 # Apache-2.0 -ipaddress>=1.0.17;python_version<'3.3' # PSF oslo.config>=5.2.0 # Apache-2.0 oslo.log>=3.36.0 # Apache-2.0 oslo.serialization!=2.19.1,>=2.18.0 # Apache-2.0 diff --git a/setup.cfg b/setup.cfg index 2362d54d2..b77670ae0 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-manilaclient/latest/ +python-requires = >=3.6 classifier = Development Status :: 5 - Production/Stable Environment :: Console @@ -19,11 +20,6 @@ classifier = Programming Language :: Python :: 3.6 Programming Language :: Python :: 3.7 - -[global] -setup-hooks = - pbr.hooks.setup_hook - [files] packages = manilaclient @@ -60,9 +56,6 @@ openstack.share.v2 = share_type_access_list = manilaclient.osc.v2.share_type_access:ListShareTypeAccess share_type_access_delete = manilaclient.osc.v2.share_type_access:ShareTypeAccessDeny -[wheel] -universal = 1 - [coverage:run] omit = manilaclient/tests/* branch = true diff --git a/setup.py b/setup.py index 566d84432..cd35c3c35 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)