From f0d24c40907666f435172eb76021c62b5b52f258163f6097cd9efa09a7ebda32 Mon Sep 17 00:00:00 2001 From: Matej Cepl Date: Thu, 13 Jan 2022 12:44:10 +0000 Subject: [PATCH] Accepting request 945708 from home:bnavigator:branches:devel:languages:python - Fix deprecated collections.abc imports still not fully fixed in 0.8.4 -- gh#arista-eosplus/pyeapi#195 - Use the PyPI archive, because the git source has the wrong version in its metadata OBS-URL: https://build.opensuse.org/request/show/945708 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pyeapi?expand=0&rev=8 --- pyeapi-0.8.4.tar.gz | 4 ++-- python-pyeapi.changes | 8 ++++++++ python-pyeapi.spec | 13 +++++++++---- 3 files changed, 19 insertions(+), 6 deletions(-) diff --git a/pyeapi-0.8.4.tar.gz b/pyeapi-0.8.4.tar.gz index b37f00d..e0537be 100644 --- a/pyeapi-0.8.4.tar.gz +++ b/pyeapi-0.8.4.tar.gz @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e4a7e617d1cc29d5dd66324435455b53003ec7cb90aeeec9a15a5c0cf35e416e -size 137621 +oid sha256:c33ad1eadd8ebac75f63488df9412081ce0b024c9e1da12a37196a5c60427c54 +size 138140 diff --git a/python-pyeapi.changes b/python-pyeapi.changes index 82cc29f..422ddbd 100644 --- a/python-pyeapi.changes +++ b/python-pyeapi.changes @@ -1,3 +1,11 @@ +------------------------------------------------------------------- +Tue Jan 11 22:08:03 UTC 2022 - Ben Greiner + +- Fix deprecated collections.abc imports still not fully fixed in + 0.8.4 -- gh#arista-eosplus/pyeapi#195 +- Use the PyPI archive, because the git source has the wrong + version in its metadata + ------------------------------------------------------------------- Sat Nov 14 13:15:51 UTC 2020 - Martin Hauke diff --git a/python-pyeapi.spec b/python-pyeapi.spec index d1ad245..9dd046e 100644 --- a/python-pyeapi.spec +++ b/python-pyeapi.spec @@ -1,7 +1,7 @@ # # spec file for package python-pyeapi # -# Copyright (c) 2020 SUSE LLC +# Copyright (c) 2022 SUSE LLC # Copyright (c) 2017-2020, Martin Hauke # # All modifications and additions to the file contributed by third parties @@ -17,7 +17,8 @@ # -%{?!python_module:%define python_module() python-%{**} python3-%{**}} +%{?!python_module:%define python_module() python3-%{**}} +%define skip_python2 1 Name: python-pyeapi Version: 0.8.4 Release: 0 @@ -25,7 +26,7 @@ Summary: Python Client for eAPI License: BSD-3-Clause Group: Development/Languages/Python URL: https://github.com/arista-eosplus/pyeapi -Source: https://github.com/arista-eosplus/pyeapi/archive/v%{version}.tar.gz#/pyeapi-%{version}.tar.gz +Source: https://files.pythonhosted.org/packages/source/p/pyeapi/pyeapi-%{version}.tar.gz BuildRequires: %{python_module mock} BuildRequires: %{python_module netaddr} BuildRequires: %{python_module pytest} @@ -52,6 +53,9 @@ developing custom implementations. %prep %setup -q -n pyeapi-%{version} +# Deprecated collections usage since Python 3.3 +sed -i 's/from collections import/from collections.abc import/' pyeapi/api/abstract.py +sed -i 's/collections.Iterable/collections.abc.Iterable/' test/unit/test_utils.py %build %python_build @@ -67,6 +71,7 @@ developing custom implementations. %license LICENSE %doc CHANGELOG.md README.md %doc examples -%{python_sitelib}/* +%{python_sitelib}/pyeapi +%{python_sitelib}/pyeapi-%{version}*-info %changelog