Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package python-hid-parser for 
openSUSE:Factory checked in at 2024-11-20 17:03:03
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-hid-parser (Old)
 and      /work/SRC/openSUSE:Factory/.python-hid-parser.new.28523 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "python-hid-parser"

Wed Nov 20 17:03:03 2024 rev:2 rq:1225264 version:0.0.3

Changes:
--------
--- /work/SRC/openSUSE:Factory/python-hid-parser/python-hid-parser.changes      
2022-11-08 10:54:04.189641384 +0100
+++ 
/work/SRC/openSUSE:Factory/.python-hid-parser.new.28523/python-hid-parser.changes
   2024-11-20 17:05:12.153763617 +0100
@@ -1,0 +2,6 @@
+Wed Nov 20 10:23:16 UTC 2024 - Dirk Müller <[email protected]>
+
+- add pytest-catch-warnings.patch to fix build with newer
+  pytest/python 3.13
+
+-------------------------------------------------------------------

New:
----
  pytest-catch-warnings.patch

BETA DEBUG BEGIN:
  New:
- add pytest-catch-warnings.patch to fix build with newer
  pytest/python 3.13
BETA DEBUG END:

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ python-hid-parser.spec ++++++
--- /var/tmp/diff_new_pack.TWidMO/_old  2024-11-20 17:05:12.597782119 +0100
+++ /var/tmp/diff_new_pack.TWidMO/_new  2024-11-20 17:05:12.597782119 +0100
@@ -1,7 +1,7 @@
 #
-# spec file
+# spec file for package python-hid-parser
 #
-# Copyright (c) 2022 SUSE LLC
+# Copyright (c) 2024 SUSE LLC
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -17,14 +17,15 @@
 
 
 %define pkg_name hid-parser
-
+%{?sle15_python_module_pythons}
 Name:           python-%{pkg_name}
 Version:        0.0.3
 Release:        0
 Summary:        Parse HID report descriptors
 License:        MIT
 URL:            https://github.com/FFY00/python-hid-parser
-Source0:        
https://files.pythonhosted.org/packages/48/af/6266119b18570fee7dc838c3389e37db3586a4e2003de709cf4ac24e395a/hid-parser-0.0.3.tar.gz
+Source0:        
https://files.pythonhosted.org/packages/source/h/hid-parser/hid-parser-%{version}.tar.gz
+Patch1:         pytest-catch-warnings.patch
 BuildRequires:  %{python_module pip}
 BuildRequires:  %{python_module setuptools}
 BuildRequires:  %{python_module wheel}
@@ -42,7 +43,7 @@
 Typed pure Python library to parse HID report descriptors
 
 %prep
-%setup -q -n %{pkg_name}-%{version}
+%autosetup -p1 -n %{pkg_name}-%{version}
 
 %build
 %pyproject_wheel

++++++ pytest-catch-warnings.patch ++++++
--- hid-parser-0.0.3/tests/test_items.py
+++ hid-parser-0.0.3/tests/test_items.py
@@ -5,7 +5,7 @@
 import pytest
 
 import hid_parser
-
+import warnings
 
 def test_baseitem():
     item = hid_parser.BaseItem(1, 2)
@@ -129,14 +129,18 @@
     with pytest.warns(hid_parser.HIDComplianceWarning):
         hid_parser.VariableItem(1, 2, 0, hid_parser.Usage(0x0001, 0x0001), -1, 
1)
 
-    with pytest.warns(None):
+    with warnings.catch_warnings():
         hid_parser.VariableItem(1, 2, 0, hid_parser.Usage(0x0001, 0x0030), -1, 
1)
+        warnings.simplefilter("error")
 
-    with pytest.warns(None):
+    with warnings.catch_warnings():
         hid_parser.VariableItem(1, 2, 0, hid_parser.Usage(0x0001, 0x0000), -1, 
1)
+        warnings.simplefilter("error")
 
-    with pytest.warns(None):
+    with warnings.catch_warnings():
         hid_parser.VariableItem(1, 2, 0, hid_parser.Usage(0x0000, 0x0000), -1, 
1)
+        warnings.simplefilter("error")
+
 
 
 def test_arrayitem():
@@ -179,11 +183,14 @@
     with pytest.warns(hid_parser.HIDComplianceWarning):
         hid_parser.ArrayItem(1, 2, 0, usages, -1, 1)
 
-    with pytest.warns(None):
+    with warnings.catch_warnings():
         hid_parser.ArrayItem(1, 2, 0, usages, -1, 1)
+        warnings.simplefilter("error")
 
-    with pytest.warns(None):
+    with warnings.catch_warnings():
         hid_parser.ArrayItem(1, 2, 0, usages, -1, 1)
+        warnings.simplefilter("error")
 
-    with pytest.warns(None):
+    with warnings.catch_warnings():
         hid_parser.ArrayItem(1, 2, 0, usages, -1, 1)
+        warnings.simplefilter("error")

Reply via email to