From 4076336b47cf0d8a7bcb822471c51bb39c450847bd92653d3fe2c3f87d6488c6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Chv=C3=A1tal?= Date: Wed, 27 May 2020 10:13:36 +0000 Subject: [PATCH] Accepting request 809232 from home:pgajdos:python submit OBS-URL: https://build.opensuse.org/request/show/809232 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-devpi-client?expand=0&rev=7 --- python-devpi-client.changes | 5 +++++ python-devpi-client.spec | 14 ++++++++++++-- 2 files changed, 17 insertions(+), 2 deletions(-) diff --git a/python-devpi-client.changes b/python-devpi-client.changes index ac70428..db40b5f 100644 --- a/python-devpi-client.changes +++ b/python-devpi-client.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Tue May 26 07:22:38 UTC 2020 - Petr Gajdos + +- %python3_only -> %python_alternative + ------------------------------------------------------------------- Sun Jan 12 00:54:29 CET 2020 - Matej Cepl diff --git a/python-devpi-client.spec b/python-devpi-client.spec index da0c174..ed33602 100644 --- a/python-devpi-client.spec +++ b/python-devpi-client.spec @@ -36,6 +36,8 @@ Requires: python-pluggy >= 0.6.0 Requires: python-py >= 1.4.31 Requires: python-tox >= 3.1.0 Requires: python-wheel +Requires(post): update-alternatives +Requires(postun): update-alternatives Recommends: git-core Recommends: python-Sphinx BuildArch: noarch @@ -72,6 +74,7 @@ sed -i 's/"python", "setup.py"/sys.executable, "setup.py"/' testing/test_test.py %install %python_install +%python_clone -a %{buildroot}%{_bindir}/devpi %python_expand %fdupes %{buildroot}%{$python_sitelib} %check @@ -79,12 +82,19 @@ export LANG=en_US.UTF-8 export PYTHONDONTWRITEBYTECODE=1 export PATH=$PATH:%{buildroot}/%{_bindir} # Unknown failures https://github.com/devpi/devpi/issues/706 -%pytest -k 'not (test_simple_install_new_venv_workflow or test_simple_install_activated_venv_workflow)' +# test_help: devpi binary is not available (update-alternatives) +%pytest -k 'not (test_simple_install_new_venv_workflow or test_simple_install_activated_venv_workflow or test_help)' + +%post +%python_install_alternative devpi + +%postun +%python_uninstall_alternative devpi %files %{python_files} %doc AUTHORS CHANGELOG README.rst %license LICENSE -%python3_only %{_bindir}/devpi +%python_alternative %{_bindir}/devpi %{python_sitelib}/* %changelog