Update to 0.17.6

Signed-off-by: Tony Asleson <tasleson@redhat.com>
This commit is contained in:
Tony Asleson 2022-04-13 09:10:59 -05:00
parent ab3524ac47
commit 5a021439fa
7 changed files with 74 additions and 18 deletions

1
.gitignore vendored
View File

@ -12,3 +12,4 @@
/pywbem-0.14.6.tar.gz
/pywbem-1.0.1.tar.gz
/pywbem-0.15.0.tar.gz
/pywbem-0.17.6.tar.gz

View File

@ -1,8 +1,8 @@
diff --git a/minimum-constraints.txt b/minimum-constraints.txt
index a3ba9471..8dd066ca 100644
index 570295ab..e771637b 100644
--- a/minimum-constraints.txt
+++ b/minimum-constraints.txt
@@ -56,7 +56,6 @@ wheel==0.33.6; python_version >= '3.8'
@@ -92,7 +92,6 @@ wheel==0.33.5; python_version >= '3.8'
# Direct dependencies for install (must be consistent with requirements.txt)
M2Crypto==0.31.0
@ -11,7 +11,7 @@ index a3ba9471..8dd066ca 100644
ply==3.10
PyYAML==3.11; python_version == '2.6'
diff --git a/pywbem_mock/_wbemconnection_mock.py b/pywbem_mock/_wbemconnection_mock.py
index e5dd0f8d..6ea95119 100644
index aa27b305..3eedb330 100644
--- a/pywbem_mock/_wbemconnection_mock.py
+++ b/pywbem_mock/_wbemconnection_mock.py
@@ -40,7 +40,7 @@ try:
@ -22,24 +22,26 @@ index e5dd0f8d..6ea95119 100644
+from unittest.mock import Mock
import six
try:
# pylint: disable=ungrouped-imports
diff --git a/requirements.txt b/requirements.txt
index 69a01d7c..f1287af2 100644
index 3ac782d5..1e5cd238 100644
--- a/requirements.txt
+++ b/requirements.txt
@@ -11,7 +11,6 @@
@@ -11,9 +11,6 @@
# On Windows, M2Crypto must be installed via pywbem_os_setup.bat
M2Crypto>=0.31.0; python_version < '3.0' and sys_platform != 'win32'
-mock>=2.0.0
-mock>=2.0.0,<3.0.0; python_version == '2.6'
-mock>=2.0.0,<4.0.0; python_version >= '2.7' and python_version <= '3.5'
-mock>=2.0.0; python_version >= '3.6'
ordereddict>=1.1; python_version == '2.6'
ply>=3.10
PyYAML>=3.11,<3.12; python_version == '2.6' # yaml package
# PyYAML 5.3 has removed support for Python 3.4; fixes narrow build error
diff --git a/tests/unittest/pywbem/test_cim_obj.py b/tests/unittest/pywbem/test_cim_obj.py
index 3d0e3b80..e0d9e39f 100755
index 2f6b89d2..d3f8a9aa 100755
--- a/tests/unittest/pywbem/test_cim_obj.py
+++ b/tests/unittest/pywbem/test_cim_obj.py
@@ -12,7 +12,7 @@ from __future__ import absolute_import, print_function
@@ -9,7 +9,7 @@ from __future__ import absolute_import, print_function
import sys
import re
from datetime import timedelta, datetime
@ -49,7 +51,7 @@ index 3d0e3b80..e0d9e39f 100755
from collections import OrderedDict
except ImportError:
diff --git a/tests/unittest/pywbem/test_itermethods.py b/tests/unittest/pywbem/test_itermethods.py
index 635bd130..7343f6fe 100644
index f7d0f8da..c613c3df 100644
--- a/tests/unittest/pywbem/test_itermethods.py
+++ b/tests/unittest/pywbem/test_itermethods.py
@@ -24,7 +24,7 @@ from __future__ import absolute_import, print_function
@ -59,10 +61,10 @@ index 635bd130..7343f6fe 100644
-from mock import Mock
+from unittest.mock import Mock
# pylint: disable=wrong-import-position, wrong-import-order, invalid-name
from ...utils import import_installed
pywbem = import_installed('pywbem') # noqa: E402
diff --git a/tests/unittest/pywbem/test_valuemapping.py b/tests/unittest/pywbem/test_valuemapping.py
index 27f86588..db31d3c3 100644
index bf93b87c..263294a5 100644
--- a/tests/unittest/pywbem/test_valuemapping.py
+++ b/tests/unittest/pywbem/test_valuemapping.py
@@ -7,7 +7,7 @@ from __future__ import absolute_import
@ -72,5 +74,5 @@ index 27f86588..db31d3c3 100644
-from mock import Mock
+from unittest.mock import Mock
# pylint: disable=wrong-import-position, wrong-import-order, invalid-name
from ...utils import import_installed
pywbem = import_installed('pywbem') # noqa: E402

View File

@ -0,0 +1,15 @@
diff --git a/pywbem/_recorder.py b/pywbem/_recorder.py
index f5b2b7d6..70de34fe 100644
--- a/pywbem/_recorder.py
+++ b/pywbem/_recorder.py
@@ -689,8 +689,8 @@ class LogOperationRecorder(BaseOperationRecorder):
# Format the 'summary' and 'paths' detail_levels
if self.api_detail_level == 'summary': # pylint: disable=R1705
if isinstance(ret, list):
- if ret:
- ret_type = type(ret[0]).__name__ if ret else ""
+ if len(ret) > 0:
+ ret_type = type(ret[0]).__name__
return _format("list of {0}; count={1}",
ret_type, len(ret))
return "Empty"

View File

@ -0,0 +1,12 @@
diff --git a/pywbem/_cim_obj.py b/pywbem/_cim_obj.py
index d91a2cb1..5c9a69a5 100644
--- a/pywbem/_cim_obj.py
+++ b/pywbem/_cim_obj.py
@@ -1954,6 +1954,7 @@ class CIMInstanceName(_CIMComparisonMixin):
_format("WBEM URI has an invalid format for its keybindings: "
"{0!A}", keybindings_str))
+ kb_assigns = []
if m.group(1):
kb_assigns = [m.group(1)]

View File

@ -0,0 +1,19 @@
diff --git a/pywbem/_cim_xml.py b/pywbem/_cim_xml.py
index 133b070d..c0ad603e 100644
--- a/pywbem/_cim_xml.py
+++ b/pywbem/_cim_xml.py
@@ -1829,12 +1829,12 @@ class RESPONSEDESTINATION(CIMElement):
::
- <!ELEMENT RESPONSEDESTINATON (INSTANCE)>
+ <!ELEMENT RESPONSEDESTINATION (INSTANCE)>
"""
def __init__(self, data):
# We use call by class name because it is an old-style class.
- CIMElement.__init__(self, 'RESPONSEDESTINATON')
+ CIMElement.__init__(self, 'RESPONSEDESTINATION')
self.appendChild(data)

View File

@ -1,14 +1,17 @@
%{?python_enable_dependency_generator}
Name: pywbem
Version: 0.15.0
Version: 0.17.6
Epoch: 1
Release: 7%{?dist}
Release: 1%{?dist}
Summary: Python WBEM client interface and related utilities
License: LGPLv2
URL: https://github.com/pywbem/pywbem
Source0: https://github.com/pywbem/pywbem/archive/v%{version}/%{name}-%{version}.tar.gz
Patch1: BZ_1922368.patch
Patch1: 0001-use-unittest-mock.patch
Patch2: 0002-coverity-deadcode.patch
Patch3: 0003-coverity-forward-null.patch
Patch4: 0004-coverity-identifier-typo.patch
BuildRequires: python3-pip python3-PyYAML python3-ply python3-rpm-macros
BuildRequires: python3-devel
BuildRequires: python3-setuptools
@ -68,6 +71,10 @@ mv -v %{buildroot}/%{_bindir}/wbemcli.py %{buildroot}/%{_bindir}/pywbemcli.py
%doc README.rst
%changelog
* Tue Apr 12 2022 Tony Asleson <tasleson@redhat.com> - 1:0.17.6-1
- Update to 0.17.6 which is the latest release that doesn't introduce
dependencies which we don't have available.
* Fri Jan 21 2022 Fedora Release Engineering <releng@fedoraproject.org> - 1:0.15.0-7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild

View File

@ -1 +1 @@
SHA512 (pywbem-0.15.0.tar.gz) = a5d8855cfb0987b89eee104c03f25649dff28b350ce92d822c76d00fea47e162d754dad31f0c1e4d88c137410649f46d79a0e4019e646bc8f58d4ead5fc9bf0c
SHA512 (pywbem-0.17.6.tar.gz) = c5950f912ee5f7050d667808664644b9801941f9bb415682c36d20c4f5683d6627bbd963c748ffb651bf38274a6d57e5343967a36f9b69dd70a47f8290398a26