diff --git a/backport-Skip-tests-requiring-invoke.patch b/backport-Skip-tests-requiring-invoke.patch new file mode 100644 index 0000000000000000000000000000000000000000..3499e8d3b7b713378b0ecf88c8beda9dbd92122a --- /dev/null +++ b/backport-Skip-tests-requiring-invoke.patch @@ -0,0 +1,37 @@ +From 2dc654a20c4f1908d587060809a9d67b31352497 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= +Date: Thu, 16 Apr 2020 09:46:39 +0200 +Subject: [PATCH] Skip tests requiring invoke if it's not installed + +Since invoke is an optional dependency and only one group of tests +require it, skip them gracefully rather than failing if it's not +present. +--- + tests/test_config.py | 7 ++++++- + 1 file changed, 6 insertions(+), 1 deletion(-) + +diff --git a/tests/test_config.py b/tests/test_config.py +index 5e9aa0592..2095061f2 100644 +--- a/tests/test_config.py ++++ b/tests/test_config.py +@@ -6,7 +6,11 @@ + + from paramiko.py3compat import string_types + +-from invoke import Result ++try: ++ from invoke import Result ++except ImportError: ++ Result = None ++ + from mock import patch + from pytest import raises, mark, fixture + +@@ -705,6 +709,7 @@ def inner(command, *args, **kwargs): + return inner + + ++@mark.skipif(Result is None, reason="requires invoke package") + class TestMatchExec(object): + @patch("paramiko.config.invoke", new=None) + @patch("paramiko.config.invoke_import_error", new=ImportError("meh")) diff --git a/paramiko-2.7.2.tar.gz b/paramiko-2.7.2.tar.gz deleted file mode 100644 index 1aea7d6ea3bcef1c8309c4e9ab200df89f885d4f..0000000000000000000000000000000000000000 Binary files a/paramiko-2.7.2.tar.gz and /dev/null differ diff --git a/paramiko-2.8.1.tar.gz b/paramiko-2.8.1.tar.gz new file mode 100644 index 0000000000000000000000000000000000000000..d778feacd2e0068d2cdd02fdb115f05ac555f2b1 Binary files /dev/null and b/paramiko-2.8.1.tar.gz differ diff --git a/python-paramiko.spec b/python-paramiko.spec index 95ebaa4a723c3aa9f2a60a30b06df3699c0977cd..a584cd9ee130a70af998edbc0f47c0b89ed2cac7 100644 --- a/python-paramiko.spec +++ b/python-paramiko.spec @@ -1,12 +1,15 @@ Name: python-paramiko -Version: 2.7.2 -Release: 1 +Version: 2.8.1 +Release: 2 Summary: Python SSH module License: LGPLv2+ URL: https://github.com/paramiko/paramiko Source0: https://github.com/paramiko/paramiko/archive/%{version}/paramiko-%{version}.tar.gz Patch0: paramiko-2.7.2-drop-pytest-relaxed.patch +# Skip tests requiring invoke if it's not installed +# Can be removed when https://github.com/paramiko/paramiko/pull/1667/ is released +Patch6000: backport-Skip-tests-requiring-invoke.patch BuildArch: noarch @@ -19,9 +22,9 @@ connections to remote machines. Summary: Python SSH module BuildRequires: python3-devel python3-setuptools python3-bcrypt >= 3.1.3 python3-pytest BuildRequires: python3-cryptography >= 2.5 python3-pyasn1 >= 0.1.7 python3-pynacl >= 1.0.1 -BuildRequires: python3-invoke >= 1.3 python3-mock >= 2.0 +BuildRequires: python3-mock >= 2.0 Requires: python3-bcrypt >= 3.1.3 python3-cryptography >= 1.5 -Requires: python3-pyasn1 >= 0.1.7 python3-pynacl >= 1.0.1 python3-invoke >= 1.3 +Requires: python3-pyasn1 >= 0.1.7 python3-pynacl >= 1.0.1 %{?python_provide:%python_provide python3-paramiko} %description -n python3-paramiko @@ -66,6 +69,12 @@ PYTHONPATH=%{buildroot}%{python3_sitelib} pytest-%{python3_version} %doc html/ demos/ NEWS README.rst %changelog +* Sat Feb 26 2022 zhanzhimin - 2.8.1-2 +- drop invoke dependencies as it requires ancient pytest + +* Wed Dec 01 2021 zhanzhimin - 2.8.1-1 +- update to 2.8.1 + * Thu Jan 28 2021 zhaorenhai - 2.7.2-1 - Upgrade to 2.7.2