Script 'mail_helper' called by obssrc
Hello community,
here is the log from the commit of package python-iniparse for openSUSE:Factory
checked in at 2023-08-16 14:16:27
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-iniparse (Old)
and /work/SRC/openSUSE:Factory/.python-iniparse.new.11712 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-iniparse"
Wed Aug 16 14:16:27 2023 rev:27 rq:1103946 version:0.5
Changes:
--------
--- /work/SRC/openSUSE:Factory/python-iniparse/python-iniparse.changes
2022-11-08 10:53:47.537542292 +0100
+++
/work/SRC/openSUSE:Factory/.python-iniparse.new.11712/python-iniparse.changes
2023-08-16 14:16:31.302746404 +0200
@@ -1,0 +2,5 @@
+Mon Aug 14 21:46:26 UTC 2023 - Dirk Müller <[email protected]>
+
+- add python311-compat.patch to fix build with python 3.11/12
+
+-------------------------------------------------------------------
New:
----
python311-compat.patch
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python-iniparse.spec ++++++
--- /var/tmp/diff_new_pack.oyuaeI/_old 2023-08-16 14:16:32.122751595 +0200
+++ /var/tmp/diff_new_pack.oyuaeI/_new 2023-08-16 14:16:32.126751621 +0200
@@ -1,7 +1,7 @@
#
# spec file for package python-iniparse
#
-# Copyright (c) 2022 SUSE LLC
+# Copyright (c) 2023 SUSE LLC
# Copyright (c) 2017 Neal Gompa <[email protected]>.
#
# All modifications and additions to the file contributed by third parties
@@ -31,6 +31,8 @@
Patch1: python-iniparse-no-python2.patch
#
https://github.com/candlepin/python-iniparse/commit/b3684a45d02af784d3d8f6ea680a351b38a865dc
Patch2: python-iniparse-no-six.patch
+# from https://github.com/candlepin/python-iniparse/pull/24
+Patch3: python311-compat.patch
BuildRequires: %{python_module setuptools}
BuildRequires: fdupes
BuildRequires: python-rpm-macros
@@ -52,6 +54,7 @@
%patch0
%patch1 -p1
%patch2 -p1
+%patch3 -p1
chmod 644 html/index.html
sed -i "/.*test_multiprocessing.*/d" tests/__init__.py # NOTE(saschpe):
Doesn't work and I'm lazy
++++++ python311-compat.patch ++++++
>From d9a083bafaa2df338a3176ee9f1433718b3a1090 Mon Sep 17 00:00:00 2001
From: Jiri Hnidek <[email protected]>
Date: Wed, 11 May 2022 14:29:27 +0200
Subject: [PATCH] Fix compatibility issues with Python 3.11
* Fixes: https://github.com/candlepin/python-iniparse/issues/23
* BZ: https://bugzilla.redhat.com/show_bug.cgi?id=2019017
* Replaced few deprecated methods with new methods
---
tests/test_compat.py | 20 ++++++++++----------
tests/test_fuzz.py | 2 +-
2 files changed, 11 insertions(+), 11 deletions(-)
diff --git a/tests/test_compat.py b/tests/test_compat.py
index ad36683..c8e6aca 100644
--- a/tests/test_compat.py
+++ b/tests/test_compat.py
@@ -96,16 +96,16 @@ def test_basic(self):
eq(cf.get('Spaces', 'key with spaces'), 'value')
eq(cf.get('Spaces', 'another with spaces'), 'splat!')
- self.failIf('__name__' in cf.options("Foo Bar"),
+ self.assertFalse('__name__' in cf.options("Foo Bar"),
'__name__ "option" should not be exposed by the API!')
# Make sure the right things happen for remove_option();
# added to include check for SourceForge bug #123324:
- self.failUnless(cf.remove_option('Foo Bar', 'foo'),
+ self.assertTrue(cf.remove_option('Foo Bar', 'foo'),
"remove_option() failed to report existance of option")
- self.failIf(cf.has_option('Foo Bar', 'foo'),
+ self.assertFalse(cf.has_option('Foo Bar', 'foo'),
"remove_option() failed to remove option")
- self.failIf(cf.remove_option('Foo Bar', 'foo'),
+ self.assertFalse(cf.remove_option('Foo Bar', 'foo'),
"remove_option() failed to report non-existance of option"
" that was removed")
@@ -127,10 +127,10 @@ def test_case_sensitivity(self):
eq(cf.options("a"), ["b"])
eq(cf.get("a", "b"), "value",
"could not locate option, expecting case-insensitive option names")
- self.failUnless(cf.has_option("a", "b"))
+ self.assertTrue(cf.has_option("a", "b"))
cf.set("A", "A-B", "A-B value")
for opt in ("a-b", "A-b", "a-B", "A-B"):
- self.failUnless(
+ self.assertTrue(
cf.has_option("A", opt),
"has_option() returned false for option which should exist")
eq(cf.options("A"), ["a-b"])
@@ -147,7 +147,7 @@ def test_case_sensitivity(self):
# SF bug #561822:
cf = self.fromstring("[section]\nnekey=nevalue\n",
defaults={"key":"value"})
- self.failUnless(cf.has_option("section", "Key"))
+ self.assertTrue(cf.has_option("section", "Key"))
def test_default_case_sensitivity(self):
cf = self.newconfig({"foo": "Bar"})
@@ -182,7 +182,7 @@ def test_query_errors(self):
cf = self.newconfig()
self.assertEqual(cf.sections(), [],
"new ConfigParser should have no defined sections")
- self.failIf(cf.has_section("Foo"),
+ self.assertFalse(cf.has_section("Foo"),
"new ConfigParser should have no acknowledged sections")
self.assertRaises(ConfigParser.NoSectionError,
cf.options, "Foo")
@@ -221,8 +221,8 @@ def test_boolean(self):
"E5=FALSE AND MORE"
)
for x in range(1, 5):
- self.failUnless(cf.getboolean('BOOLTEST', 't%d' % x))
- self.failIf(cf.getboolean('BOOLTEST', 'f%d' % x))
+ self.assertTrue(cf.getboolean('BOOLTEST', 't%d' % x))
+ self.assertFalse(cf.getboolean('BOOLTEST', 'f%d' % x))
self.assertRaises(ValueError,
cf.getboolean, 'BOOLTEST', 'e%d' % x)
diff --git a/tests/test_fuzz.py b/tests/test_fuzz.py
index df568bb..874ef2e 100644
--- a/tests/test_fuzz.py
+++ b/tests/test_fuzz.py
@@ -102,7 +102,7 @@ def test_fuzz(self):
cc = compat.RawConfigParser()
cc.readfp(StringIO(s))
cc_py = configparser.RawConfigParser()
- cc_py.readfp(StringIO(s))
+ cc_py.read_file(StringIO(s))
# compare the two configparsers
self.assertEqualConfig(cc_py, cc)
# check that tidy does not change semantics