From 4d917605c815a765d98400141938a367bed9903c7a576c2afc726a042f250e41 Mon Sep 17 00:00:00 2001 From: Matej Cepl Date: Mon, 10 Jan 2022 14:47:11 +0000 Subject: [PATCH] Accepting request 945346 from home:bnavigator:branches:devel:languages:python - Fix test and runtime requirements OBS-URL: https://build.opensuse.org/request/show/945346 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-injector?expand=0&rev=16 --- python-injector.changes | 7 ++++++- python-injector.spec | 19 ++++++++++++------- 2 files changed, 18 insertions(+), 8 deletions(-) diff --git a/python-injector.changes b/python-injector.changes index 8195167..7ebefc3 100644 --- a/python-injector.changes +++ b/python-injector.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Mon Jan 10 13:55:04 UTC 2022 - Ben Greiner + +- Fix test and runtime requirements + ------------------------------------------------------------------- Fri Dec 31 13:01:20 UTC 2021 - Matej Cepl @@ -46,7 +51,7 @@ Wed Jul 24 13:38:20 UTC 2019 - pgajdos@suse.com * Deprecated using :func:`provider ` for multibindings * Fixed failure to provide a default value to a `NewType`-aliased type with auto_bind enabled * Deprecated :func:`Key `, :func:`SequenceKey ` and - :func:`MappingKey ` – use real types or type aliases instead + :func:`MappingKey ` – use real types or type aliases instead * Deprecated using single-item lists and dictionaries for multibindings - use real types or type aliases instead Technically backwards incompatible: * typing.List and typing.Dict specializations are now explicitly disallowed as :meth:`bind ` diff --git a/python-injector.spec b/python-injector.spec index de21427..e270d65 100644 --- a/python-injector.spec +++ b/python-injector.spec @@ -1,7 +1,7 @@ # # spec file for package python-injector # -# Copyright (c) 2021 SUSE LLC +# Copyright (c) 2022 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -25,15 +25,19 @@ Summary: Python dependency injection framework, inspired by Guice License: BSD-3-Clause URL: https://github.com/alecthomas/injector Source: https://github.com/alecthomas/injector/archive/%{version}.tar.gz -BuildRequires: %{python_module pytest} BuildRequires: %{python_module setuptools} -BuildRequires: %{python_module typing_extensions >= 3.7.4} +BuildRequires: %{python_module typing_extensions >= 3.7.4 if %python-base < 3.9} +# SECTION test requirements +BuildRequires: %{python_module pytest} +BuildRequires: %{python_module dataclasses if %python-base < 3.7} +# /SECTION BuildRequires: %{pythons} BuildRequires: fdupes -BuildRequires: python-rpm-macros -BuildRequires: ((python3-dataclasses and python3-base < 3.7) or (python36-dataclasses and python36-base)) +BuildRequires: python-rpm-macros >= 20210131 Requires: python -Requires: (python-typing_extensions if python-base < 3.8) +%if %{python_version_nodots} < 39 +Requires: python-typing_extensions >= 3.7.4 +%endif BuildArch: noarch %python_subpackages @@ -69,6 +73,7 @@ rm pytest.ini %files %{python_files} %license COPYING %doc README.md -%{python_sitelib}/* +%{python_sitelib}/injector +%{python_sitelib}/injector-%{version}*-info %changelog