Cleanup py27 support

Removes and/or replaces all mentions of py27.

Cleans up obsolete requirements and their lower-constraints.

Change-Id: Id43f1bbd6a454832ab8dbf003a058403f6b34b5d
This commit is contained in:
Radosław Piliszek 2020-04-17 17:18:46 +02:00
parent b6d152e92d
commit 6c480c3d89
8 changed files with 12 additions and 38 deletions

View File

@ -30,11 +30,11 @@ See the `unit testing <https://wiki.openstack.org/wiki/Testing#Unit_Tests>`__
section of the Testing wiki page for more information. section of the Testing wiki page for more information.
Following are some simple examples. Following are some simple examples.
To run the Python 2.7 tests: To run the Python 3.7 tests:
.. code-block:: console .. code-block:: console
tox -e py27 tox -e py37
To run the style tests: To run the style tests:
@ -46,7 +46,7 @@ To run multiple tests separate items by commas:
.. code-block:: console .. code-block:: console
tox -e py27,py37,pep8 tox -e py37,pep8
Running a subset of tests Running a subset of tests
------------------------- -------------------------
@ -59,27 +59,27 @@ To run the tests located only in the ``kolla/tests`` directory:
.. code-block:: console .. code-block:: console
tox -e py27 kolla.tests tox -e py37 kolla.tests
To run the tests of a specific file say ``kolla/tests/test_set_config.py``: To run the tests of a specific file say ``kolla/tests/test_set_config.py``:
.. code-block:: console .. code-block:: console
tox -e py27 test_set_config tox -e py37 test_set_config
To run the tests in the ``ConfigFileTest`` class in To run the tests in the ``ConfigFileTest`` class in
the ``kolla/tests/test_set_config.py`` file: the ``kolla/tests/test_set_config.py`` file:
.. code-block:: console .. code-block:: console
tox -e py27 test_set_config.ConfigFileTest tox -e py37 test_set_config.ConfigFileTest
To run the ``ConfigFileTest.test_delete_path_not_exists`` test method in To run the ``ConfigFileTest.test_delete_path_not_exists`` test method in
the ``kolla/tests/test_set_config.py`` file: the ``kolla/tests/test_set_config.py`` file:
.. code-block:: console .. code-block:: console
tox -e py27 test_set_config.ConfigFileTest.test_delete_path_not_exists tox -e py37 test_set_config.ConfigFileTest.test_delete_path_not_exists
Coverage Report Generation Coverage Report Generation
-------------------------- --------------------------

View File

@ -65,15 +65,10 @@ LABEL maintainer="{{ maintainer }}" name="{{ image_name }}" build-date="{{ build
{% if base_arch =='x86_64' %} {% if base_arch =='x86_64' %}
{% set collectd_packages = collectd_packages + [ {% set collectd_packages = collectd_packages + [
'collectd-hugepages', 'collectd-hugepages',
'collectd-pmu',
'collectd-rdt', 'collectd-rdt',
'collectd-turbostat' 'collectd-turbostat'
] %} ] %}
{% if distro_python_version.startswith('3') %}
{% set collectd_packages = collectd_packages + [
'collectd-pmu'
] %}
{% endif %}
{% endif %} {% endif %}
{% if base_arch != 's390x' %} {% if base_arch != 's390x' %}

View File

@ -732,7 +732,7 @@ class KollaWorker(object):
self.conf.distro_python_version = "3.6" self.conf.distro_python_version = "3.6"
else: else:
# Assume worst # Assume worst
self.conf.distro_python_version = "2.7" self.conf.distro_python_version = "3.6"
if self.conf.distro_package_manager is not None: if self.conf.distro_package_manager is not None:
package_manager = self.conf.distro_package_manager package_manager = self.conf.distro_package_manager

View File

@ -39,7 +39,6 @@ monotonic==1.4
mox3==0.25.0 mox3==0.25.0
msgpack==0.5.6 msgpack==0.5.6
munch==2.2.0 munch==2.2.0
netaddr==0.7.18
netifaces==0.10.6 netifaces==0.10.6
openstacksdk==0.12.0 openstacksdk==0.12.0
os-client-config==1.29.0 os-client-config==1.29.0
@ -50,7 +49,6 @@ oslo.context==2.20.0
oslo.i18n==3.20.0 oslo.i18n==3.20.0
oslo.log==3.36.0 oslo.log==3.36.0
oslo.serialization==2.25.0 oslo.serialization==2.25.0
oslo.utils==3.33.0
oslotest==3.2.0 oslotest==3.2.0
packaging==17.1 packaging==17.1
pbr==2.0.0 pbr==2.0.0
@ -77,7 +75,6 @@ PyYAML==3.10
requests==2.18.4 requests==2.18.4
requestsexceptions==1.4.0 requestsexceptions==1.4.0
rfc3986==1.2.0 rfc3986==1.2.0
setuptools==21.0
simplejson==3.13.2 simplejson==3.13.2
six==1.10.0 six==1.10.0
smmap2==2.0.3 smmap2==2.0.3

View File

@ -1,11 +1,5 @@
# 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.
pbr!=2.1.0,>=2.0.0 # Apache-2.0 pbr!=2.1.0,>=2.0.0 # Apache-2.0
docker>=2.4.2 # Apache-2.0 docker>=2.4.2 # Apache-2.0
Jinja2>=2.8 # BSD License (3 clause) Jinja2>=2.8 # BSD License (3 clause)
GitPython>=1.0.1 # BSD License (3 clause) GitPython>=1.0.1 # BSD License (3 clause)
oslo.config>=5.1.0 # Apache-2.0 oslo.config>=5.1.0 # Apache-2.0
oslo.utils>=3.33.0 # Apache-2.0
setuptools!=24.0.0,!=34.0.0,!=34.0.1,!=34.0.2,!=34.0.3,!=34.1.0,!=34.1.1,!=34.2.0,!=34.3.0,!=34.3.1,!=34.3.2,!=36.2.0,>=21.0 # PSF/ZPL
netaddr>=0.7.18 # BSD

View File

@ -6,6 +6,7 @@ description-file =
author = OpenStack author = OpenStack
author-email = openstack-discuss@lists.openstack.org author-email = openstack-discuss@lists.openstack.org
home-page = https://docs.openstack.org/kolla/latest/ home-page = https://docs.openstack.org/kolla/latest/
python-requires = >=3.6
license = Apache License, Version 2.0 license = Apache License, Version 2.0
classifier = classifier =
Environment :: OpenStack Environment :: OpenStack
@ -14,6 +15,8 @@ classifier =
License :: OSI Approved :: Apache Software License License :: OSI Approved :: Apache Software License
Operating System :: POSIX :: Linux Operating System :: POSIX :: Linux
Programming Language :: Python Programming Language :: Python
Programming Language :: Python :: Implementation :: CPython
Programming Language :: Python :: 3 :: Only
Programming Language :: Python :: 3 Programming Language :: Python :: 3
Programming Language :: Python :: 3.6 Programming Language :: Python :: 3.6
Programming Language :: Python :: 3.7 Programming Language :: Python :: 3.7
@ -36,8 +39,3 @@ console_scripts =
kolla-build = kolla.cmd.build:main kolla-build = kolla.cmd.build:main
oslo.config.opts = oslo.config.opts =
kolla = kolla.opts:list_opts kolla = kolla.opts:list_opts
[build_releasenotes]
all_files = 1
build-dir = releasenotes/build
source-dir = releasenotes/source

View File

@ -13,17 +13,8 @@
# See the License for the specific language governing permissions and # See the License for the specific language governing permissions and
# limitations under the License. # limitations under the License.
# THIS FILE IS MANAGED BY THE GLOBAL REQUIREMENTS REPO - DO NOT EDIT
import setuptools 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( setuptools.setup(
setup_requires=['pbr>=2.0.0'], setup_requires=['pbr>=2.0.0'],
pbr=True) pbr=True)

View File

@ -9,7 +9,6 @@ basepython = python3
usedevelop=True usedevelop=True
whitelist_externals = find whitelist_externals = find
rm rm
install_command = pip install {opts} {packages}
deps = -c{env:UPPER_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master} deps = -c{env:UPPER_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
-r{toxinidir}/requirements.txt -r{toxinidir}/requirements.txt
-r{toxinidir}/test-requirements.txt -r{toxinidir}/test-requirements.txt