From 954c98f5e2a70e708fcc181db6fa31ee39ac5e61 Mon Sep 17 00:00:00 2001 From: Kevin Fenzi Date: Aug 07 2021 21:26:55 +0000 Subject: Second attempt - Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild --- diff --git a/python-daemon-safe_hasattr.patch b/python-daemon-safe_hasattr.patch new file mode 100644 index 0000000..0721855 --- /dev/null +++ b/python-daemon-safe_hasattr.patch @@ -0,0 +1,20 @@ +diff --color -Nur python-daemon-2.3.0.orig/test/test_metadata.py python-daemon-2.3.0/test/test_metadata.py +--- python-daemon-2.3.0.orig/test/test_metadata.py 2021-02-20 21:45:31.000000000 -0800 ++++ python-daemon-2.3.0/test/test_metadata.py 2021-08-07 14:13:30.307834642 -0700 +@@ -28,6 +28,7 @@ + import pkg_resources + import testtools.helpers + import testtools.matchers ++import extras + + from . import scaffold + from .scaffold import unicode +@@ -44,7 +45,7 @@ + def match(self, instance): + """ Assert the object `instance` has an attribute named `name`. """ + result = None +- if not testtools.helpers.safe_hasattr(instance, self.attribute_name): ++ if not extras.safe_hasattr(instance, self.attribute_name): + result = AttributeNotFoundMismatch(instance, self.attribute_name) + return result + diff --git a/python-daemon.spec b/python-daemon.spec index d9d5285..63e770a 100644 --- a/python-daemon.spec +++ b/python-daemon.spec @@ -18,6 +18,8 @@ Patch0: remove-twine-dependency.patch # https://pagure.io/python-daemon/pull-request/56 Patch1: tests-remove-duplicate-mocking.patch +Patch2: python-daemon-safe_hasattr.patch + BuildArch: noarch BuildRequires: python%{python3_pkgversion}-devel, BuildRequires: python%{python3_pkgversion}-setuptools @@ -28,6 +30,7 @@ BuildRequires: python%{python3_pkgversion}-testscenarios BuildRequires: python%{python3_pkgversion}-lockfile BuildRequires: python%{python3_pkgversion}-mock BuildRequires: python%{python3_pkgversion}-testtools +BuildRequires: python%{python3_pkgversion}-extras %endif %global _description\