Skip to content

Commit d86f7ea

Browse files
committed
Update python3 to rev 98 via SR 812851
https://build.opensuse.org/request/show/812851 by user mcepl + dimstar_suse - add requires python3-base on libpython subpackage (bsc#1167008) - build against Sphinx 2.x until python is compatible with Sphinx 3.x (see gh#python/cpython#19397, bpo#40204) - Fix build with SQLite 3.32 (bpo#40783) add bpo40784-Fix-sqlite3-deterministic-test.patch
1 parent 970fc42 commit d86f7ea

9 files changed

Lines changed: 161 additions & 4 deletions

‎packages/p/python3/.files‎

84 Bytes
Binary file not shown.

‎packages/p/python3/.rev‎

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1161,4 +1161,18 @@ http://lists.opensuse.org/opensuse-packaging/2012-09/msg00254.html</comment>
11611161
<comment></comment>
11621162
<requestid>806764</requestid>
11631163
</revision>
1164+
<revision rev="98" vrev="2">
1165+
<srcmd5>cc38e661737d3e48b4029c270bf24054</srcmd5>
1166+
<version>3.8.3</version>
1167+
<time>1591879350</time>
1168+
<user>dimstar_suse</user>
1169+
<comment>- add requires python3-base on libpython subpackage (bsc#1167008)
1170+
1171+
- build against Sphinx 2.x until python is compatible with
1172+
Sphinx 3.x (see gh#python/cpython#19397, bpo#40204)
1173+
1174+
- Fix build with SQLite 3.32 (bpo#40783)
1175+
add bpo40784-Fix-sqlite3-deterministic-test.patch</comment>
1176+
<requestid>812851</requestid>
1177+
</revision>
11641178
</revisionlist>
Lines changed: 79 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,79 @@
1+
From 00a240bf7f95bbd220f1cfbf9eb58484a5f9681a Mon Sep 17 00:00:00 2001
2+
From: "Miss Islington (bot)"
3+
<31488909+miss-islington@users.noreply.github.com>
4+
Date: Fri, 29 May 2020 05:46:34 -0700
5+
Subject: [PATCH] bpo-40784: Fix sqlite3 deterministic test (GH-20448)
6+
7+
(cherry picked from commit c610d970f5373b143bf5f5900d4645e6a90fb460)
8+
9+
Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@innova.no>
10+
---
11+
Lib/sqlite3/test/userfunctions.py | 36 +++++++++++++++++++++++--------
12+
1 file changed, 27 insertions(+), 9 deletions(-)
13+
14+
diff --git a/Lib/sqlite3/test/userfunctions.py b/Lib/sqlite3/test/userfunctions.py
15+
index 9501f535c4999..c11c82e127577 100644
16+
--- a/Lib/sqlite3/test/userfunctions.py
17+
+++ b/Lib/sqlite3/test/userfunctions.py
18+
@@ -1,8 +1,7 @@
19+
-#-*- coding: iso-8859-1 -*-
20+
# pysqlite2/test/userfunctions.py: tests for user-defined functions and
21+
# aggregates.
22+
#
23+
-# Copyright (C) 2005-2007 Gerhard Häring <gh@ghaering.de>
24+
+# Copyright (C) 2005-2007 Gerhard Häring <gh@ghaering.de>
25+
#
26+
# This file is part of pysqlite.
27+
#
28+
@@ -158,6 +157,7 @@ def setUp(self):
29+
self.con.create_function("isblob", 1, func_isblob)
30+
self.con.create_function("islonglong", 1, func_islonglong)
31+
self.con.create_function("spam", -1, func)
32+
+ self.con.execute("create table test(t text)")
33+
34+
def tearDown(self):
35+
self.con.close()
36+
@@ -276,18 +276,36 @@ def CheckAnyArguments(self):
37+
val = cur.fetchone()[0]
38+
self.assertEqual(val, 2)
39+
40+
+ # Regarding deterministic functions:
41+
+ #
42+
+ # Between 3.8.3 and 3.15.0, deterministic functions were only used to
43+
+ # optimize inner loops, so for those versions we can only test if the
44+
+ # sqlite machinery has factored out a call or not. From 3.15.0 and onward,
45+
+ # deterministic functions were permitted in WHERE clauses of partial
46+
+ # indices, which allows testing based on syntax, iso. the query optimizer.
47+
+ @unittest.skipIf(sqlite.sqlite_version_info < (3, 8, 3), "Requires SQLite 3.8.3 or higher")
48+
def CheckFuncNonDeterministic(self):
49+
mock = unittest.mock.Mock(return_value=None)
50+
- self.con.create_function("deterministic", 0, mock, deterministic=False)
51+
- self.con.execute("select deterministic() = deterministic()")
52+
- self.assertEqual(mock.call_count, 2)
53+
-
54+
- @unittest.skipIf(sqlite.sqlite_version_info < (3, 8, 3), "deterministic parameter not supported")
55+
+ self.con.create_function("nondeterministic", 0, mock, deterministic=False)
56+
+ if sqlite.sqlite_version_info < (3, 15, 0):
57+
+ self.con.execute("select nondeterministic() = nondeterministic()")
58+
+ self.assertEqual(mock.call_count, 2)
59+
+ else:
60+
+ with self.assertRaises(sqlite.OperationalError):
61+
+ self.con.execute("create index t on test(t) where nondeterministic() is not null")
62+
+
63+
+ @unittest.skipIf(sqlite.sqlite_version_info < (3, 8, 3), "Requires SQLite 3.8.3 or higher")
64+
def CheckFuncDeterministic(self):
65+
mock = unittest.mock.Mock(return_value=None)
66+
self.con.create_function("deterministic", 0, mock, deterministic=True)
67+
- self.con.execute("select deterministic() = deterministic()")
68+
- self.assertEqual(mock.call_count, 1)
69+
+ if sqlite.sqlite_version_info < (3, 15, 0):
70+
+ self.con.execute("select deterministic() = deterministic()")
71+
+ self.assertEqual(mock.call_count, 1)
72+
+ else:
73+
+ try:
74+
+ self.con.execute("create index t on test(t) where deterministic() is not null")
75+
+ except sqlite.OperationalError:
76+
+ self.fail("Unexpected failure while creating partial index")
77+
78+
@unittest.skipIf(sqlite.sqlite_version_info >= (3, 8, 3), "SQLite < 3.8.3 needed")
79+
def CheckFuncDeterministicNotSupported(self):

‎packages/p/python3/python3-base.changes‎

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,20 @@
1+
-------------------------------------------------------------------
2+
Mon Jun 8 14:26:00 UTC 2020 - Matej Cepl <mcepl@suse.com>
3+
4+
- add requires python3-base on libpython subpackage (bsc#1167008)
5+
6+
-------------------------------------------------------------------
7+
Fri Jun 5 06:08:12 UTC 2020 - Dirk Mueller <dmueller@suse.com>
8+
9+
- build against Sphinx 2.x until python is compatible with
10+
Sphinx 3.x (see gh#python/cpython#19397, bpo#40204)
11+
12+
-------------------------------------------------------------------
13+
Fri May 29 19:59:01 UTC 2020 - Andreas Stieger <andreas.stieger@gmx.de>
14+
15+
- Fix build with SQLite 3.32 (bpo#40783)
16+
add bpo40784-Fix-sqlite3-deterministic-test.patch
17+
118
-------------------------------------------------------------------
219
Sun May 17 15:37:35 UTC 2020 - Callum Farmer <callumjfarmer13@gmail.com>
320

‎packages/p/python3/python3-base.spec‎

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ Source101: python3-base-rpmlintrc
101101
Source102: pre_checkin.sh
102102
Source103: skipped_tests.py
103103
##### REQURES, PROVIDES, OBSOLETES #####
104-
Requires: libpython%{so_version} == %{version}-%{release}
104+
Requires: libpython%{so_version} = %{version}-%{release}
105105
Requires: python-rpm-macros
106106
Recommends: python3 = %{version}
107107
#Recommends: python3-ensurepip
@@ -204,6 +204,9 @@ Patch29: bpo-31046_ensurepip_honours_prefix.patch
204204
# PATCH-FIX-UPSTREAM bsc1167501-invalid-alignment.patch gh#python/cpython#19133 mcepl@suse.com
205205
# Fix wrong misalignment of pointer to vectorcallfunc
206206
Patch31: bsc1167501-invalid-alignment.patch
207+
# PATCH-FIX-UPSTREAM bpo40784-Fix-sqlite3-deterministic-test.patch bpo#40784 Andreas.Stieger@gmx.de
208+
# Fix tests with SQLite 3.32
209+
Patch32: bpo40784-Fix-sqlite3-deterministic-test.patch
207210
### COMMON-PATCH-END ###
208211

209212
%description
@@ -260,6 +263,7 @@ They are a documented part of stdlib, as a module 'test'.
260263
%package -n libpython%{so_version}
261264
Summary: Python Interpreter shared library
262265
Group: Development/Languages/Python
266+
Requires: python3-base >= %{version}
263267

264268
%description -n libpython%{so_version}
265269
Python is an interpreted, object-oriented programming language, and is
@@ -298,6 +302,7 @@ other applications.
298302
%patch28 -p1
299303
%patch29 -p1
300304
%patch31 -p1
305+
%patch32 -p1
301306

302307
# drop Autoconf version requirement
303308
sed -i 's/^AC_PREREQ/dnl AC_PREREQ/' configure.ac

‎packages/p/python3/python3-doc.changes‎

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,22 @@
11
-------------------------------------------------------------------
2-
Sun May 17 15:40:11 UTC 2020 - Callum Farmer <callumjfarmer13@gmail.com>
2+
Mon Jun 8 14:26:00 UTC 2020 - Matej Cepl <mcepl@suse.com>
3+
4+
- add requires python3-base on libpython subpackage (bsc#1167008)
5+
6+
-------------------------------------------------------------------
7+
Fri Jun 5 06:08:12 UTC 2020 - Dirk Mueller <dmueller@suse.com>
8+
9+
- build against Sphinx 2.x until python is compatible with
10+
Sphinx 3.x (see gh#python/cpython#19397, bpo#40204)
11+
12+
-------------------------------------------------------------------
13+
Fri May 29 19:59:01 UTC 2020 - Andreas Stieger <andreas.stieger@gmx.de>
14+
15+
- Fix build with SQLite 3.32 (bpo#40783)
16+
add bpo40784-Fix-sqlite3-deterministic-test.patch
17+
18+
-------------------------------------------------------------------
19+
Sun May 17 15:37:35 UTC 2020 - Callum Farmer <callumjfarmer13@gmail.com>
320

421
- Update to version 3.8.3:
522
- Complete list of changes is available at

‎packages/p/python3/python3-doc.spec‎

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ Source0: http://www.python.org/ftp/python/%{folderversion}/%{tarname}.tar
8282
Source1: http://www.python.org/ftp/python/%{folderversion}/%{tarname}.tar.xz.asc
8383
Source99: python.keyring
8484
BuildRequires: libqt5-qttools
85-
BuildRequires: python3-Sphinx >= 1.8
85+
BuildRequires: python3-Sphinx < 3.0
8686
BuildRequires: python3-python-docs-theme
8787
BuildRequires: python3-sphinxcontrib-qthelp >= 1.0.2
8888
BuildRequires: xz
@@ -138,6 +138,9 @@ Patch29: bpo-31046_ensurepip_honours_prefix.patch
138138
# PATCH-FIX-UPSTREAM bsc1167501-invalid-alignment.patch gh#python/cpython#19133 mcepl@suse.com
139139
# Fix wrong misalignment of pointer to vectorcallfunc
140140
Patch31: bsc1167501-invalid-alignment.patch
141+
# PATCH-FIX-UPSTREAM bpo40784-Fix-sqlite3-deterministic-test.patch bpo#40784 Andreas.Stieger@gmx.de
142+
# Fix tests with SQLite 3.32
143+
Patch32: bpo40784-Fix-sqlite3-deterministic-test.patch
141144
### COMMON-PATCH-END ###
142145

143146
%description
@@ -184,6 +187,7 @@ Python, and Macintosh Module Reference in format for devhelp.
184187
%patch28 -p1
185188
%patch29 -p1
186189
%patch31 -p1
190+
%patch32 -p1
187191

188192
# drop Autoconf version requirement
189193
sed -i 's/^AC_PREREQ/dnl AC_PREREQ/' configure.ac

‎packages/p/python3/python3.changes‎

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,22 @@
11
-------------------------------------------------------------------
2-
Sun May 17 15:40:53 UTC 2020 - Callum Farmer <callumjfarmer13@gmail.com>
2+
Mon Jun 8 14:26:00 UTC 2020 - Matej Cepl <mcepl@suse.com>
3+
4+
- add requires python3-base on libpython subpackage (bsc#1167008)
5+
6+
-------------------------------------------------------------------
7+
Fri Jun 5 06:08:12 UTC 2020 - Dirk Mueller <dmueller@suse.com>
8+
9+
- build against Sphinx 2.x until python is compatible with
10+
Sphinx 3.x (see gh#python/cpython#19397, bpo#40204)
11+
12+
-------------------------------------------------------------------
13+
Fri May 29 19:59:01 UTC 2020 - Andreas Stieger <andreas.stieger@gmx.de>
14+
15+
- Fix build with SQLite 3.32 (bpo#40783)
16+
add bpo40784-Fix-sqlite3-deterministic-test.patch
17+
18+
-------------------------------------------------------------------
19+
Sun May 17 15:37:35 UTC 2020 - Callum Farmer <callumjfarmer13@gmail.com>
320

421
- Update to version 3.8.3:
522
- Complete list of changes is available at

‎packages/p/python3/python3.spec‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -176,6 +176,9 @@ Patch29: bpo-31046_ensurepip_honours_prefix.patch
176176
# PATCH-FIX-UPSTREAM bsc1167501-invalid-alignment.patch gh#python/cpython#19133 mcepl@suse.com
177177
# Fix wrong misalignment of pointer to vectorcallfunc
178178
Patch31: bsc1167501-invalid-alignment.patch
179+
# PATCH-FIX-UPSTREAM bpo40784-Fix-sqlite3-deterministic-test.patch bpo#40784 Andreas.Stieger@gmx.de
180+
# Fix tests with SQLite 3.32
181+
Patch32: bpo40784-Fix-sqlite3-deterministic-test.patch
179182
### COMMON-PATCH-END ###
180183

181184
%description
@@ -257,6 +260,7 @@ a debugger.
257260
%patch28 -p1
258261
%patch29 -p1
259262
%patch31 -p1
263+
%patch32 -p1
260264

261265
# drop Autoconf version requirement
262266
sed -i 's/^AC_PREREQ/dnl AC_PREREQ/' configure.ac

0 commit comments

Comments
 (0)