From 6329bea968ac923fc445aacf0fbe66ce7d3fac3e Mon Sep 17 00:00:00 2001 From: Charalampos Stratakis Date: Sat, 6 Aug 2022 04:46:59 +0200 Subject: [PATCH] Update to 7.0.5 Resolves: rhbz#2106018 --- fix-test-assumptions.patch | 27 +++++++++++++++++++++++++++ python-setuptools_scm.spec | 12 ++++++++++-- sources | 2 +- 3 files changed, 38 insertions(+), 3 deletions(-) create mode 100644 fix-test-assumptions.patch diff --git a/fix-test-assumptions.patch b/fix-test-assumptions.patch new file mode 100644 index 0000000..070147b --- /dev/null +++ b/fix-test-assumptions.patch @@ -0,0 +1,27 @@ +diff --git a/testing/test_git.py b/testing/test_git.py +index 52384424..321d6585 100644 +--- a/testing/test_git.py ++++ b/testing/test_git.py +@@ -24,7 +24,6 @@ + from setuptools_scm import NonNormalizedVersion + from setuptools_scm.file_finder_git import git_find_files + from setuptools_scm.git import archival_to_version +-from setuptools_scm.utils import data_from_mime + from setuptools_scm.utils import do + from setuptools_scm.utils import has_command + +@@ -546,12 +545,9 @@ def test_git_archival_node_missing_no_version() -> None: + assert version is None + + +-def test_git_archhival_from_unfiltered() -> None: ++def test_git_archival_from_unfiltered() -> None: + config = Configuration() + +- import setuptools_scm +- +- data = data_from_mime(Path(setuptools_scm.__file__).parent / ".git_archival.txt") + with pytest.warns(UserWarning, match="unexported git archival found"): +- version = archival_to_version(data, config=config) ++ version = archival_to_version({"node": "$Format:%H$"}, config=config) + assert version is None diff --git a/python-setuptools_scm.spec b/python-setuptools_scm.spec index e024092..3f0b720 100644 --- a/python-setuptools_scm.spec +++ b/python-setuptools_scm.spec @@ -1,14 +1,18 @@ %bcond_without tests Name: python-setuptools_scm -Version: 7.0.4 -Release: 2%{?dist} +Version: 7.0.5 +Release: 1%{?dist} Summary: Blessed package to manage your versions by SCM tags License: MIT URL: https://pypi.python.org/pypi/setuptools_scm Source0: %{pypi_source setuptools_scm} +# Fix test_git_archhival_from_unfiltered assumptions +# Resolved upstream: https://github.com/pypa/setuptools_scm/pull/757 +Patch0: fix-test-assumptions.patch + BuildArch: noarch BuildRequires: python%{python3_pkgversion}-devel @@ -68,6 +72,10 @@ It also handles file finders for the supported SCMs. %changelog +* Sat Aug 06 2022 Charalampos Stratakis - 7.0.5-1 +- Update to 7.0.5 +Resolves: rhbz#2106018 + * Fri Jul 22 2022 Fedora Release Engineering - 7.0.4-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild diff --git a/sources b/sources index e4764d6..9f0f8ad 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (setuptools_scm-7.0.4.tar.gz) = cdd1f36fab5b0fa9c1f3dc42c57ee732fbc7b39e761b2db3047c9e953ddc28dd6bbc29b44451e77f602c4ea39469af86a7b08d2d6ab1513b938193e000c3c04e +SHA512 (setuptools_scm-7.0.5.tar.gz) = 5b3420f0aaa0dd1655afb0fdcedc3738b75dbb9d8205e0ad67555c251d330a0d3620a7297cfdcfabbc7386a8acf43fe73fa7f3b17e2d156495fd8b2ab7d1c985