From 62ed425ae7683109fd4c7d3ba214937235b6e3975467f5e88de9b48dcf77a0a3 Mon Sep 17 00:00:00 2001 From: Matej Cepl Date: Sun, 7 Oct 2018 06:35:21 +0000 Subject: [PATCH 1/4] Partially switch off tests requiring testscenarios and stestr. OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pbr?expand=0&rev=98 --- python-pbr.changes | 5 +++++ python-pbr.spec | 6 +++--- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/python-pbr.changes b/python-pbr.changes index 19e9301..f849d39 100644 --- a/python-pbr.changes +++ b/python-pbr.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Sun Oct 7 06:34:26 UTC 2018 - Matěj Cepl + +- Partially switch off tests requiring testscenarios and stestr. + ------------------------------------------------------------------- Fri Sep 14 21:18:14 UTC 2018 - dmueller@suse.com diff --git a/python-pbr.spec b/python-pbr.spec index 2d77313..1d90f4e 100644 --- a/python-pbr.spec +++ b/python-pbr.spec @@ -12,7 +12,7 @@ # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. -# Please submit bugfixes or comments via http://bugs.opensuse.org/ +# Please submit bugfixes or comments via https://bugs.opensuse.org/ # @@ -50,8 +50,8 @@ BuildRequires: %{python_module devel} BuildRequires: %{python_module fixtures >= 3.0.0} BuildRequires: %{python_module mock >= 2.0} BuildRequires: %{python_module six >= 1.9.0} -BuildRequires: %{python_module stestr} -BuildRequires: %{python_module testresources >= 2.0.0} +# BuildRequires: %{python_module stestr} +# BuildRequires: %{python_module testresources >= 2.0.0} BuildRequires: %{python_module testscenarios >= 0.4} BuildRequires: %{python_module testtools >= 2.2.0} BuildRequires: %{python_module virtualenv >= 14.0.6} From 2e855cc977f1a5dea11532614cf6889c1986cb31a3f73b471a27c9ad2ffb9cd0 Mon Sep 17 00:00:00 2001 From: Matej Cepl Date: Sun, 7 Oct 2018 06:38:58 +0000 Subject: [PATCH 2/4] no stestr OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pbr?expand=0&rev=99 --- python-pbr.spec | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/python-pbr.spec b/python-pbr.spec index 1d90f4e..888dee6 100644 --- a/python-pbr.spec +++ b/python-pbr.spec @@ -51,7 +51,7 @@ BuildRequires: %{python_module fixtures >= 3.0.0} BuildRequires: %{python_module mock >= 2.0} BuildRequires: %{python_module six >= 1.9.0} # BuildRequires: %{python_module stestr} -# BuildRequires: %{python_module testresources >= 2.0.0} +BuildRequires: %{python_module testresources >= 2.0.0} BuildRequires: %{python_module testscenarios >= 0.4} BuildRequires: %{python_module testtools >= 2.2.0} BuildRequires: %{python_module virtualenv >= 14.0.6} @@ -92,7 +92,8 @@ chmod -x pbr/tests/testpackage/setup.py %if %{with test} %check -%python_exec -m stestr.cli run +# %%python_exec -m stestr.cli run +%python_exec -m unittest -v discover %endif %if !%{with test} From 79969e5e24662c9e2a3e85e2f00ae8ed84f70ce49c59e2ba6f83e1a855014e46 Mon Sep 17 00:00:00 2001 From: Matej Cepl Date: Sun, 7 Oct 2018 06:43:57 +0000 Subject: [PATCH 3/4] Revert previous commit. OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pbr?expand=0&rev=100 --- python-pbr.changes | 5 +++++ python-pbr.spec | 5 ++--- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/python-pbr.changes b/python-pbr.changes index f849d39..997204d 100644 --- a/python-pbr.changes +++ b/python-pbr.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Sun Oct 7 08:43:14 CEST 2018 - mcepl@suse.com + +- Revert previous commit. + ------------------------------------------------------------------- Sun Oct 7 06:34:26 UTC 2018 - Matěj Cepl diff --git a/python-pbr.spec b/python-pbr.spec index 888dee6..dd43da6 100644 --- a/python-pbr.spec +++ b/python-pbr.spec @@ -50,7 +50,7 @@ BuildRequires: %{python_module devel} BuildRequires: %{python_module fixtures >= 3.0.0} BuildRequires: %{python_module mock >= 2.0} BuildRequires: %{python_module six >= 1.9.0} -# BuildRequires: %{python_module stestr} +BuildRequires: %{python_module stestr} BuildRequires: %{python_module testresources >= 2.0.0} BuildRequires: %{python_module testscenarios >= 0.4} BuildRequires: %{python_module testtools >= 2.2.0} @@ -92,8 +92,7 @@ chmod -x pbr/tests/testpackage/setup.py %if %{with test} %check -# %%python_exec -m stestr.cli run -%python_exec -m unittest -v discover +%python_exec -m stestr.cli run %endif %if !%{with test} From 2e566a5b2eaf84d215f4fde67c3eb99f53b20ca2653b8489da5ac6e35a8b65e0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Chv=C3=A1tal?= Date: Tue, 16 Oct 2018 16:01:32 +0000 Subject: [PATCH 4/4] Accepting request 642395 from home:mcepl:pbr - Update to 4.3.0: * Remove my\_ip from generated wsgi script * Fix typo in contribution instructions * Add release note for fix to bug 1786306 * Move pbr-installation jobs in-tree * Support subdirectory in the url * remove pypy jobs * add lib-forward-testing-python3 test job * add python 3.6 unit test job * switch documentation job to new PTI * import zuul job settings from project-config * Ignore Zuul when generating AUTHORS * tox: Re-add cover target - Add new_wheel.patch to make compatible with wheel = 0.32.1 OBS-URL: https://build.opensuse.org/request/show/642395 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pbr?expand=0&rev=101 --- new_wheel.patch | 59 ++++++++++++++++++++++++++++++++++++++++++++++ pbr-4.2.0.tar.gz | 3 --- pbr-4.3.0.tar.gz | 3 +++ python-pbr.changes | 18 ++++++++++++++ python-pbr.spec | 5 ++-- 5 files changed, 83 insertions(+), 5 deletions(-) create mode 100644 new_wheel.patch delete mode 100644 pbr-4.2.0.tar.gz create mode 100644 pbr-4.3.0.tar.gz diff --git a/new_wheel.patch b/new_wheel.patch new file mode 100644 index 0000000..8fe0ef6 --- /dev/null +++ b/new_wheel.patch @@ -0,0 +1,59 @@ +--- a/pbr/tests/test_packaging.py ++++ b/pbr/tests/test_packaging.py +@@ -41,6 +41,7 @@ + import email + import email.errors + import imp ++import logging + import os + import re + import sys +@@ -56,8 +57,11 @@ import testscenarios + import testtools + from testtools import matchers + import virtualenv +-import wheel.install ++try: ++ from wheel.install import WheelFile ++except ImportError: ++ from wheel.wheelfile import WheelFile + + from pbr import git + from pbr import packaging + from pbr.tests import base +@@ -372,13 +376,15 @@ class TestPackagingWheels(base.BaseTestC + relative_wheel_filename = os.listdir(dist_dir)[0] + absolute_wheel_filename = os.path.join( + dist_dir, relative_wheel_filename) +- wheel_file = wheel.install.WheelFile(absolute_wheel_filename) +- wheel_name = wheel_file.parsed_filename.group('namever') +- # Create a directory path to unpack the wheel to +- self.extracted_wheel_dir = os.path.join(dist_dir, wheel_name) +- # Extract the wheel contents to the directory we just created +- wheel_file.zipfile.extractall(self.extracted_wheel_dir) +- wheel_file.zipfile.close() ++ with WheelFile(absolute_wheel_filename) as wheel_file: ++ wheel_name = wheel_file.parsed_filename.group('namever') ++ # Create a directory path to unpack the wheel to ++ self.extracted_wheel_dir = os.path.join(dist_dir, wheel_name) ++ # Extract the wheel contents to the directory we just created ++ if hasattr(wheel_file, 'zipfile'): ++ wheel_file.zipfile.extractall(self.extracted_wheel_dir) ++ else: ++ wheel_file.extractall(self.extracted_wheel_dir) + + def test_data_directory_has_wsgi_scripts(self): + # Build the path to the scripts directory +@@ -402,8 +409,10 @@ class TestPackagingWheels(base.BaseTestC + static_object_path = os.path.join( + built_package_dir, static_object_filename) + +- self.assertTrue(os.path.exists(built_package_dir)) +- self.assertTrue(os.path.exists(static_object_path)) ++ self.assertTrue(os.path.exists(built_package_dir), ++ 'built_package_dir %s not found!' % built_package_dir) ++ self.assertTrue(os.path.exists(static_object_path), ++ 'static_object_path %s not found!' % static_object_path) + + + class TestPackagingHelpers(testtools.TestCase): diff --git a/pbr-4.2.0.tar.gz b/pbr-4.2.0.tar.gz deleted file mode 100644 index a6b9cce..0000000 --- a/pbr-4.2.0.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:1b8be50d938c9bb75d0eaf7eda111eec1bf6dc88a62a6412e33bf077457e0f45 -size 107958 diff --git a/pbr-4.3.0.tar.gz b/pbr-4.3.0.tar.gz new file mode 100644 index 0000000..705526a --- /dev/null +++ b/pbr-4.3.0.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1be135151a0da949af8c5d0ee9013d9eafada71237eb80b3ba8896b4f12ec5dc +size 112935 diff --git a/python-pbr.changes b/python-pbr.changes index 997204d..c4c0318 100644 --- a/python-pbr.changes +++ b/python-pbr.changes @@ -1,3 +1,21 @@ +------------------------------------------------------------------- +Mon Oct 15 13:23:36 UTC 2018 - Matej Cepl + +- Update to 4.3.0: + * Remove my\_ip from generated wsgi script + * Fix typo in contribution instructions + * Add release note for fix to bug 1786306 + * Move pbr-installation jobs in-tree + * Support subdirectory in the url + * remove pypy jobs + * add lib-forward-testing-python3 test job + * add python 3.6 unit test job + * switch documentation job to new PTI + * import zuul job settings from project-config + * Ignore Zuul when generating AUTHORS + * tox: Re-add cover target +- Add new_wheel.patch to make compatible with wheel = 0.32.1 + ------------------------------------------------------------------- Sun Oct 7 08:43:14 CEST 2018 - mcepl@suse.com diff --git a/python-pbr.spec b/python-pbr.spec index dd43da6..7d9a197 100644 --- a/python-pbr.spec +++ b/python-pbr.spec @@ -28,7 +28,7 @@ Name: python-pbr %else Name: python-pbr-%{flavor} %endif -Version: 4.2.0 +Version: 4.3.0 Release: 0 Summary: Python Build Reasonableness License: Apache-2.0 @@ -36,6 +36,7 @@ Group: Development/Languages/Python URL: http://pypi.python.org/pypi/pbr Source: https://files.pythonhosted.org/packages/source/p/pbr/pbr-%{version}.tar.gz Patch0: 0001-Skip-test-for-testr-hook-being-installed-when-testr-.patch +Patch1: new_wheel.patch BuildRequires: %{python_module setuptools} BuildRequires: fdupes BuildRequires: python-rpm-macros @@ -70,7 +71,7 @@ information. %prep %setup -q -n pbr-%{version} -%patch0 -p1 +%autopatch -p1 # Get rid of ugly build-time deps that require network: sed -i "s/, 'sphinx\.ext\.intersphinx'//" doc/source/conf.py