From 021fe7c4420d3c9f93e682628c0c74a15446ff0239fb79c172e75459a7ab260c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mark=C3=A9ta=20Machov=C3=A1?= Date: Thu, 28 Mar 2024 08:08:12 +0000 Subject: [PATCH] Accepting request 1162950 from home:ecsos:python - Disable self_check under %check in Leap because it does not work and prevent package building. OBS-URL: https://build.opensuse.org/request/show/1162950 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-mypy?expand=0&rev=11 --- python-mypy.changes | 6 ++++++ python-mypy.spec | 5 +++-- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/python-mypy.changes b/python-mypy.changes index 0a2c72f..4cd4d6b 100644 --- a/python-mypy.changes +++ b/python-mypy.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Wed Mar 27 15:59:56 UTC 2024 - ecsos + +- Disable self_check under %check in Leap because it does not work + and prevent package building. + ------------------------------------------------------------------- Fri Mar 22 13:48:55 UTC 2024 - Matej Cepl diff --git a/python-mypy.spec b/python-mypy.spec index 9dc8937..88f412c 100644 --- a/python-mypy.spec +++ b/python-mypy.spec @@ -51,7 +51,7 @@ Requires: python-typing_extensions >= 3.10 Requires: (python-tomli >= 1.1.0 if python-base < 3.11) Requires: (python-typed-ast >= 1.4.0 if python-base < 3.8) Requires(post): update-alternatives -Requires(postun): update-alternatives +Requires(postun):update-alternatives %if "%{python_flavor}" == "python3" || "%{?python_provides}" == "python3" Provides: mypy = %{version} Obsoletes: mypy < %{version} @@ -126,11 +126,12 @@ rm docs/make.bat %if %{with test} %check - +%if 0%{?suse_version} > 1600 %{python_expand # self-check with manually provided stubs for typed_ast export PYTHONPATH=%{buildroot}%{$python_sitelib}:./mystubs $python -m mypy --config-file mypy_self_check.ini -p mypy } +%endif unset PYTHONPATH # cannot compile unoptimized with suse headers export MYPYC_OPT_LEVEL=2