diff --git a/python-coverage.spec b/python-coverage.spec index 4311c27..1adc00c 100644 --- a/python-coverage.spec +++ b/python-coverage.spec @@ -16,7 +16,6 @@ # -%bcond_without libalternatives %{?sle15_python_module_pythons} Name: python-coverage Version: 7.7.1 @@ -26,16 +25,16 @@ License: Apache-2.0 URL: https://github.com/nedbat/coveragepy Source: https://files.pythonhosted.org/packages/source/c/coverage/coverage-%{version}.tar.gz # PATCH-FIX-UPSTREAM https://github.com/nedbat/coveragepy/commit/ba685fb8d06a2052c4916749539ef501b8080804 build: setuptools 77 doesn't like license classifiers. -Patch0: setuptools77.patch +Patch: setuptools77.patch BuildRequires: %{python_module devel >= 3.9} BuildRequires: %{python_module pip} BuildRequires: %{python_module setuptools} BuildRequires: %{python_module wheel} -BuildRequires: alts BuildRequires: fdupes BuildRequires: python-rpm-macros -Requires: alts Requires: python +Requires(post): update-alternatives +Requires(postun): update-alternatives # coverage[toml] Recommends: python-tomli # SECTION test requirements @@ -108,8 +107,11 @@ donttest+=" or test_report_wildcard or test_run_omit_vs_report_omit" %pytest_arch -n auto --no-flaky-report -k "$donttest" -rp ||: %pytest_arch -n auto --no-flaky-report -k "not ($donttest)" -%pre -%python_libalternatives_reset_alternative coverage +%post +%python_install_alternative coverage + +%postun +%python_uninstall_alternative coverage %files %{python_files} %license LICENSE.txt