From b5d38aa8d9e95bd03b01cd5cad25366324c7084c Mon Sep 17 00:00:00 2001 From: Tomas Hrnciar Date: Tue, 29 Jun 2021 08:07:05 +0200 Subject: [PATCH 01/10] Update to 3.9.6 --- 00111-no-static-lib.patch | 2 +- 00189-use-rpm-wheels.patch | 4 ++-- 00353-architecture-names-upstream-downstream.patch | 2 +- python3.9.spec | 11 +++++++---- sources | 4 ++-- 5 files changed, 13 insertions(+), 10 deletions(-) diff --git a/00111-no-static-lib.patch b/00111-no-static-lib.patch index b44dbc9..4693bbe 100644 --- a/00111-no-static-lib.patch +++ b/00111-no-static-lib.patch @@ -21,7 +21,7 @@ Co-authored-by: Miro Hrončok 1 file changed, 2 insertions(+), 19 deletions(-) diff --git a/Makefile.pre.in b/Makefile.pre.in -index 0c3981c132..5587422ec7 100644 +index 2b68571031..c57fc9693a 100644 --- a/Makefile.pre.in +++ b/Makefile.pre.in @@ -589,7 +589,7 @@ clinic: check-clean-src $(srcdir)/Modules/_blake2/blake2s_impl.c diff --git a/00189-use-rpm-wheels.patch b/00189-use-rpm-wheels.patch index 608d265..87358d9 100644 --- a/00189-use-rpm-wheels.patch +++ b/00189-use-rpm-wheels.patch @@ -12,7 +12,7 @@ We might eventually pursuit upstream support, but it's low prio 1 file changed, 22 insertions(+), 11 deletions(-) diff --git a/Lib/ensurepip/__init__.py b/Lib/ensurepip/__init__.py -index 57e576d1a3..5bd16a6c59 100644 +index 14a39037e0..5bd16a6c59 100644 --- a/Lib/ensurepip/__init__.py +++ b/Lib/ensurepip/__init__.py @@ -1,3 +1,5 @@ @@ -36,7 +36,7 @@ index 57e576d1a3..5bd16a6c59 100644 -_SETUPTOOLS_VERSION = "56.0.0" +_wheels = {} --_PIP_VERSION = "21.1.1" +-_PIP_VERSION = "21.1.3" +def _get_most_recent_wheel_version(pkg): + prefix = os.path.join(_WHEEL_DIR, "{}-".format(pkg)) + _wheels[pkg] = {} diff --git a/00353-architecture-names-upstream-downstream.patch b/00353-architecture-names-upstream-downstream.patch index 5e98140..578e786 100644 --- a/00353-architecture-names-upstream-downstream.patch +++ b/00353-architecture-names-upstream-downstream.patch @@ -34,7 +34,7 @@ Co-authored-by: Miro Hrončok 1 file changed, 38 insertions(+), 2 deletions(-) diff --git a/Lib/importlib/_bootstrap_external.py b/Lib/importlib/_bootstrap_external.py -index 7c4157369d..c3b95638a6 100644 +index fe31f437da..b5b70757f0 100644 --- a/Lib/importlib/_bootstrap_external.py +++ b/Lib/importlib/_bootstrap_external.py @@ -1636,7 +1636,7 @@ def _get_supported_file_loaders(): diff --git a/python3.9.spec b/python3.9.spec index 9abe196..4551dc8 100644 --- a/python3.9.spec +++ b/python3.9.spec @@ -13,11 +13,11 @@ URL: https://www.python.org/ # WARNING When rebasing to a new Python version, # remember to update the python3-docs package as well -%global general_version %{pybasever}.5 +%global general_version %{pybasever}.6 #global prerel ... %global upstream_version %{general_version}%{?prerel} Version: %{general_version}%{?prerel:~%{prerel}} -Release: 3%{?dist} +Release: 1%{?dist} License: Python @@ -305,7 +305,7 @@ Patch1: 00001-rpath.patch # See https://bugzilla.redhat.com/show_bug.cgi?id=556092 Patch111: 00111-no-static-lib.patch -# 00189 # 4cb983ce1c5ef32068ca9349203a6f1ef9667451 +# 00189 # 4242864a6a12f1f4cf9fd63a6699a73f35261aa3 # Instead of bundled wheels, use our RPM packaged wheels # # We keep them in /usr/share/python-wheels @@ -317,7 +317,7 @@ Patch189: 00189-use-rpm-wheels.patch # The versions are written in Lib/ensurepip/__init__.py, this patch removes them. # When the bundled setuptools/pip wheel is updated, the patch no longer applies cleanly. # In such cases, the patch needs to be amended and the versions updated here: -%global pip_version 21.1.1 +%global pip_version 21.1.3 %global setuptools_version 56.0.0 # 00251 # 2eabd04356402d488060bc8fe316ad13fc8a3356 @@ -1778,6 +1778,9 @@ CheckPython optimized # ====================================================== %changelog +* Tue Jun 29 2021 Tomas Hrnciar - 3.9.6-1 +- Update to 3.9.6 + * Tue Jun 01 2021 Python Maint - 3.9.5-3 - Rebuilt for Python 3.10 diff --git a/sources b/sources index 373c745..ca8aa55 100644 --- a/sources +++ b/sources @@ -1,2 +1,2 @@ -SHA512 (Python-3.9.5.tar.xz) = 7b581af1b3e73695f124ff6a3a960e22104153a5d920ca930c046f42ea313b1e7ec77e39876db2bf5d5da6d7412cb072ff8ae7814dda12c14f9da6c570fb0995 -SHA512 (Python-3.9.5.tar.xz.asc) = cfee8c161447544d6f18c3490b96ce12c8df5e9b143fca09734066f3606abe767cd7b4d05315c691f41c0e565d9585456774c10770ffe2ef7983a911bbcfdb83 +SHA512 (Python-3.9.6.tar.xz) = 01c529e3207738d8771caeb5ed6217e10745c21aa39832fe3185e1c87fdb6aedead97ce38dbb11e02d873654028bd8071c3f345c18452769520723284efe9dc1 +SHA512 (Python-3.9.6.tar.xz.asc) = 0673c8833f302c829bfde97453c52744f6aa99b4a72520f4cc384d4aa9d6ffd28a1407ceafb0a1ec4462b3aa74b656bf39c67872c4e6a131429ea58c47ad0ecc From aa536db3278d6e5d931e640216099fd4848dafbb Mon Sep 17 00:00:00 2001 From: Petr Viktorin Date: Wed, 30 Jun 2021 12:50:32 +0200 Subject: [PATCH 02/10] Provide python3-turtle from python3-tkinter Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1952565 --- python3.9.spec | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/python3.9.spec b/python3.9.spec index 4551dc8..6d2756e 100644 --- a/python3.9.spec +++ b/python3.9.spec @@ -17,7 +17,7 @@ URL: https://www.python.org/ #global prerel ... %global upstream_version %{general_version}%{?prerel} Version: %{general_version}%{?prerel:~%{prerel}} -Release: 1%{?dist} +Release: 2%{?dist} License: Python @@ -633,6 +633,10 @@ configuration, browsers, and other dialogs. Summary: A GUI toolkit for Python Requires: %{pkgname} = %{version}-%{release} +# The importable module "turtle" is here, so provide python3-turtle. +# (We don't provide python3-turtledemo, that's not too useful when imported.) +%py_provides %{pkgname}-turtle + %description -n %{pkgname}-tkinter The Tkinter (Tk interface) library is a graphical user interface toolkit for the Python programming language. @@ -1778,6 +1782,9 @@ CheckPython optimized # ====================================================== %changelog +* Fri Jul 16 2021 Petr Viktorin - 3.9.6-2 +- Provide python3-turtle from python3-tkinter + * Tue Jun 29 2021 Tomas Hrnciar - 3.9.6-1 - Update to 3.9.6 From 54ef9bd8ddf3686f7b0f821978a2448d389b3502 Mon Sep 17 00:00:00 2001 From: Petr Viktorin Date: Thu, 15 Jul 2021 10:58:21 +0200 Subject: [PATCH 03/10] Require pyproject-rpm-macros from python3-devel Part of the new Python packaging guidelines change: - https://fedoraproject.org/wiki/Changes/PythonPackagingGuidelines202x - https://bugzilla.redhat.com/show_bug.cgi?id=1977883 --- python3.9.spec | 2 ++ 1 file changed, 2 insertions(+) diff --git a/python3.9.spec b/python3.9.spec index 6d2756e..74aba3e 100644 --- a/python3.9.spec +++ b/python3.9.spec @@ -563,6 +563,7 @@ Requires: %{pkgname}-libs%{?_isa} = %{version}-%{release} # But we want them when packages BuildRequire python3-devel Requires: (python-rpm-macros if rpm-build) Requires: (python3-rpm-macros if rpm-build) +Requires: (pyproject-rpm-macros if rpm-build) %if %{without bootstrap} # This is not "API" (packages that need setuptools should still BuildRequire it) @@ -1784,6 +1785,7 @@ CheckPython optimized %changelog * Fri Jul 16 2021 Petr Viktorin - 3.9.6-2 - Provide python3-turtle from python3-tkinter +- Require pyproject-rpm-macros from python3-devel * Tue Jun 29 2021 Tomas Hrnciar - 3.9.6-1 - Update to 3.9.6 From 115911c72ebb77fab4a1acd8f8f794d9c4ad150b Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Fri, 23 Jul 2021 10:32:23 +0000 Subject: [PATCH 04/10] - Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild Signed-off-by: Fedora Release Engineering --- python3.9.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/python3.9.spec b/python3.9.spec index 74aba3e..ab0548b 100644 --- a/python3.9.spec +++ b/python3.9.spec @@ -17,7 +17,7 @@ URL: https://www.python.org/ #global prerel ... %global upstream_version %{general_version}%{?prerel} Version: %{general_version}%{?prerel:~%{prerel}} -Release: 2%{?dist} +Release: 3%{?dist} License: Python @@ -1783,6 +1783,9 @@ CheckPython optimized # ====================================================== %changelog +* Fri Jul 23 2021 Fedora Release Engineering - 3.9.6-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild + * Fri Jul 16 2021 Petr Viktorin - 3.9.6-2 - Provide python3-turtle from python3-tkinter - Require pyproject-rpm-macros from python3-devel From 21411c50a9009953c69bc3286c990ea6d6e3c877 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Miro=20Hron=C4=8Dok?= Date: Fri, 13 Aug 2021 01:12:28 +0200 Subject: [PATCH 05/10] Update description of the flat python3.9 package -- it is now older, not newer --- python3.9.spec | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/python3.9.spec b/python3.9.spec index ab0548b..0f88811 100644 --- a/python3.9.spec +++ b/python3.9.spec @@ -731,10 +731,10 @@ Requires: tzdata %description Python %{pybasever} package for developers. -This package exists to allow developers to test their code against a newer +This package exists to allow developers to test their code against an older version of Python. This is not a full Python stack and if you wish to run -your applications with Python %{pybasever}, update your Fedora to a newer -version once Python %{pybasever} is stable. +your applications with Python %{pybasever}, see other distributions +that support it, such as CentOS or RHEL or older Fedora releases. %endif # with flatpackage From 8020ec5862ff83f0c7de8eda12c7de463f5a9747 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Miro=20Hron=C4=8Dok?= Date: Tue, 31 Aug 2021 01:30:12 +0200 Subject: [PATCH 06/10] Update to 3.9.7 --- 00111-no-static-lib.patch | 2 +- 00189-use-rpm-wheels.patch | 6 +++--- python3.9.spec | 13 ++++++++----- sources | 4 ++-- 4 files changed, 14 insertions(+), 11 deletions(-) diff --git a/00111-no-static-lib.patch b/00111-no-static-lib.patch index 4693bbe..29a0a3d 100644 --- a/00111-no-static-lib.patch +++ b/00111-no-static-lib.patch @@ -21,7 +21,7 @@ Co-authored-by: Miro Hrončok 1 file changed, 2 insertions(+), 19 deletions(-) diff --git a/Makefile.pre.in b/Makefile.pre.in -index 2b68571031..c57fc9693a 100644 +index 6ce7a614dc..2cf3cb184e 100644 --- a/Makefile.pre.in +++ b/Makefile.pre.in @@ -589,7 +589,7 @@ clinic: check-clean-src $(srcdir)/Modules/_blake2/blake2s_impl.c diff --git a/00189-use-rpm-wheels.patch b/00189-use-rpm-wheels.patch index 87358d9..665b5e3 100644 --- a/00189-use-rpm-wheels.patch +++ b/00189-use-rpm-wheels.patch @@ -12,7 +12,7 @@ We might eventually pursuit upstream support, but it's low prio 1 file changed, 22 insertions(+), 11 deletions(-) diff --git a/Lib/ensurepip/__init__.py b/Lib/ensurepip/__init__.py -index 14a39037e0..5bd16a6c59 100644 +index 7b03970c93..5bd16a6c59 100644 --- a/Lib/ensurepip/__init__.py +++ b/Lib/ensurepip/__init__.py @@ -1,3 +1,5 @@ @@ -33,10 +33,10 @@ index 14a39037e0..5bd16a6c59 100644 +_WHEEL_DIR = "/usr/share/python-wheels/" --_SETUPTOOLS_VERSION = "56.0.0" +-_SETUPTOOLS_VERSION = "57.4.0" +_wheels = {} --_PIP_VERSION = "21.1.3" +-_PIP_VERSION = "21.2.3" +def _get_most_recent_wheel_version(pkg): + prefix = os.path.join(_WHEEL_DIR, "{}-".format(pkg)) + _wheels[pkg] = {} diff --git a/python3.9.spec b/python3.9.spec index 0f88811..adeb9f0 100644 --- a/python3.9.spec +++ b/python3.9.spec @@ -13,11 +13,11 @@ URL: https://www.python.org/ # WARNING When rebasing to a new Python version, # remember to update the python3-docs package as well -%global general_version %{pybasever}.6 +%global general_version %{pybasever}.7 #global prerel ... %global upstream_version %{general_version}%{?prerel} Version: %{general_version}%{?prerel:~%{prerel}} -Release: 3%{?dist} +Release: 1%{?dist} License: Python @@ -305,7 +305,7 @@ Patch1: 00001-rpath.patch # See https://bugzilla.redhat.com/show_bug.cgi?id=556092 Patch111: 00111-no-static-lib.patch -# 00189 # 4242864a6a12f1f4cf9fd63a6699a73f35261aa3 +# 00189 # ab9a031e2a429afce5c3e1777633d5305b956ea6 # Instead of bundled wheels, use our RPM packaged wheels # # We keep them in /usr/share/python-wheels @@ -317,8 +317,8 @@ Patch189: 00189-use-rpm-wheels.patch # The versions are written in Lib/ensurepip/__init__.py, this patch removes them. # When the bundled setuptools/pip wheel is updated, the patch no longer applies cleanly. # In such cases, the patch needs to be amended and the versions updated here: -%global pip_version 21.1.3 -%global setuptools_version 56.0.0 +%global pip_version 21.2.3 +%global setuptools_version 57.4.0 # 00251 # 2eabd04356402d488060bc8fe316ad13fc8a3356 # Change user install location @@ -1783,6 +1783,9 @@ CheckPython optimized # ====================================================== %changelog +* Mon Aug 30 2021 Miro Hrončok - 3.9.7-1 +- Update to 3.9.7 + * Fri Jul 23 2021 Fedora Release Engineering - 3.9.6-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild diff --git a/sources b/sources index ca8aa55..c0e8376 100644 --- a/sources +++ b/sources @@ -1,2 +1,2 @@ -SHA512 (Python-3.9.6.tar.xz) = 01c529e3207738d8771caeb5ed6217e10745c21aa39832fe3185e1c87fdb6aedead97ce38dbb11e02d873654028bd8071c3f345c18452769520723284efe9dc1 -SHA512 (Python-3.9.6.tar.xz.asc) = 0673c8833f302c829bfde97453c52744f6aa99b4a72520f4cc384d4aa9d6ffd28a1407ceafb0a1ec4462b3aa74b656bf39c67872c4e6a131429ea58c47ad0ecc +SHA512 (Python-3.9.7.tar.xz) = 55139776ab58a40f9e1e70613d7071d559ef9e51e32a77791422aac134322c21a49f0348c42813214b69789c589367eae43e16d4ae838a73daf37617e966b735 +SHA512 (Python-3.9.7.tar.xz.asc) = 7ff9f845f520efab3b4a0e95da3ffe055ee5777a4173a5b2cc1fd2419dc2b4faf30d1e711e372df36e34bc971ecfcde88a7cd815cfe2d8080ccb575a1ae8e101 From 1e3497ed347335b88209808216689c3f3e3d4d56 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Hrn=C4=8Diar?= Date: Mon, 8 Nov 2021 07:56:26 +0000 Subject: [PATCH 07/10] Update to 3.9.8 --- 00001-rpath.patch | 2 +- 00111-no-static-lib.patch | 10 +++++----- 00189-use-rpm-wheels.patch | 23 ++++++++++++----------- python3.9.spec | 5 ++++- sources | 4 ++-- 5 files changed, 24 insertions(+), 20 deletions(-) diff --git a/00001-rpath.patch b/00001-rpath.patch index 170908e..778c077 100644 --- a/00001-rpath.patch +++ b/00001-rpath.patch @@ -9,7 +9,7 @@ Subject: [PATCH] 00001: Fixup distutils/unixccompiler.py to remove standard 1 file changed, 9 insertions(+) diff --git a/Lib/distutils/unixccompiler.py b/Lib/distutils/unixccompiler.py -index f0792de74a..4d837936c6 100644 +index d00c48981e..0283a28c19 100644 --- a/Lib/distutils/unixccompiler.py +++ b/Lib/distutils/unixccompiler.py @@ -82,6 +82,15 @@ class UnixCCompiler(CCompiler): diff --git a/00111-no-static-lib.patch b/00111-no-static-lib.patch index 29a0a3d..390eed2 100644 --- a/00111-no-static-lib.patch +++ b/00111-no-static-lib.patch @@ -21,10 +21,10 @@ Co-authored-by: Miro Hrončok 1 file changed, 2 insertions(+), 19 deletions(-) diff --git a/Makefile.pre.in b/Makefile.pre.in -index 6ce7a614dc..2cf3cb184e 100644 +index 11230fa563..dc763e7197 100644 --- a/Makefile.pre.in +++ b/Makefile.pre.in -@@ -589,7 +589,7 @@ clinic: check-clean-src $(srcdir)/Modules/_blake2/blake2s_impl.c +@@ -588,7 +588,7 @@ clinic: check-clean-src $(srcdir)/Modules/_blake2/blake2s_impl.c $(PYTHON_FOR_REGEN) $(srcdir)/Tools/clinic/clinic.py --make --srcdir $(srcdir) # Build the interpreter @@ -33,7 +33,7 @@ index 6ce7a614dc..2cf3cb184e 100644 $(LINKCC) $(PY_CORE_LDFLAGS) $(LINKFORSHARED) -o $@ Programs/python.o $(BLDLIBRARY) $(LIBS) $(MODLIBS) $(SYSLIBS) platform: $(BUILDPYTHON) pybuilddir.txt -@@ -637,12 +637,6 @@ sharedmods: $(BUILDPYTHON) pybuilddir.txt Modules/_math.o +@@ -636,12 +636,6 @@ sharedmods: $(BUILDPYTHON) pybuilddir.txt Modules/_math.o _TCLTK_INCLUDES='$(TCLTK_INCLUDES)' _TCLTK_LIBS='$(TCLTK_LIBS)' \ $(PYTHON_FOR_BUILD) $(srcdir)/setup.py $$quiet build @@ -46,7 +46,7 @@ index 6ce7a614dc..2cf3cb184e 100644 libpython$(LDVERSION).so: $(LIBRARY_OBJS) $(DTRACE_OBJS) if test $(INSTSONAME) != $(LDLIBRARY); then \ $(BLDSHARED) -Wl,-h$(INSTSONAME) -o $(INSTSONAME) $(LIBRARY_OBJS) $(MODLIBS) $(SHLIBS) $(LIBC) $(LIBM); \ -@@ -724,7 +718,7 @@ Makefile Modules/config.c: Makefile.pre \ +@@ -723,7 +717,7 @@ Makefile Modules/config.c: Makefile.pre \ @echo "The Makefile was updated, you may need to re-run make." @@ -55,7 +55,7 @@ index 6ce7a614dc..2cf3cb184e 100644 $(LINKCC) $(PY_CORE_LDFLAGS) $(LINKFORSHARED) -o $@ Programs/_testembed.o $(BLDLIBRARY) $(LIBS) $(MODLIBS) $(SYSLIBS) ############################################################################ -@@ -1652,17 +1646,6 @@ libainstall: @DEF_MAKE_RULE@ python-config +@@ -1651,17 +1645,6 @@ libainstall: @DEF_MAKE_RULE@ python-config else true; \ fi; \ done diff --git a/00189-use-rpm-wheels.patch b/00189-use-rpm-wheels.patch index 665b5e3..e5cf8f7 100644 --- a/00189-use-rpm-wheels.patch +++ b/00189-use-rpm-wheels.patch @@ -8,11 +8,11 @@ We keep them in /usr/share/python-wheels Downstream only: upstream bundles We might eventually pursuit upstream support, but it's low prio --- - Lib/ensurepip/__init__.py | 33 ++++++++++++++++++++++----------- - 1 file changed, 22 insertions(+), 11 deletions(-) + Lib/ensurepip/__init__.py | 37 ++++++++++++++++++++++++++----------- + 1 file changed, 26 insertions(+), 11 deletions(-) diff --git a/Lib/ensurepip/__init__.py b/Lib/ensurepip/__init__.py -index 7b03970c93..5bd16a6c59 100644 +index 2a140a2624..5bd16a6c59 100644 --- a/Lib/ensurepip/__init__.py +++ b/Lib/ensurepip/__init__.py @@ -1,3 +1,5 @@ @@ -21,7 +21,7 @@ index 7b03970c93..5bd16a6c59 100644 import os import os.path import sys -@@ -6,16 +8,28 @@ import tempfile +@@ -6,13 +8,29 @@ import tempfile import subprocess from importlib import resources @@ -30,13 +30,13 @@ index 7b03970c93..5bd16a6c59 100644 __all__ = ["version", "bootstrap"] - +-_SETUPTOOLS_VERSION = "58.1.0" +-_PIP_VERSION = "21.2.4" ++ +_WHEEL_DIR = "/usr/share/python-wheels/" - --_SETUPTOOLS_VERSION = "57.4.0" ++ +_wheels = {} - --_PIP_VERSION = "21.2.3" ++ +def _get_most_recent_wheel_version(pkg): + prefix = os.path.join(_WHEEL_DIR, "{}-".format(pkg)) + _wheels[pkg] = {} @@ -51,10 +51,11 @@ index 7b03970c93..5bd16a6c59 100644 +_SETUPTOOLS_VERSION = _get_most_recent_wheel_version("setuptools") + +_PIP_VERSION = _get_most_recent_wheel_version("pip") - ++ _PROJECTS = [ ("setuptools", _SETUPTOOLS_VERSION, "py3"), -@@ -105,13 +119,10 @@ def _bootstrap(*, root=None, upgrade=False, user=False, + ("pip", _PIP_VERSION, "py3"), +@@ -101,13 +119,10 @@ def _bootstrap(*, root=None, upgrade=False, user=False, # additional paths that need added to sys.path additional_paths = [] for project, version, py_tag in _PROJECTS: diff --git a/python3.9.spec b/python3.9.spec index adeb9f0..4c7e24f 100644 --- a/python3.9.spec +++ b/python3.9.spec @@ -13,7 +13,7 @@ URL: https://www.python.org/ # WARNING When rebasing to a new Python version, # remember to update the python3-docs package as well -%global general_version %{pybasever}.7 +%global general_version %{pybasever}.8 #global prerel ... %global upstream_version %{general_version}%{?prerel} Version: %{general_version}%{?prerel:~%{prerel}} @@ -1783,6 +1783,9 @@ CheckPython optimized # ====================================================== %changelog +* Mon Nov 08 2021 Tomáš Hrnčiar - 3.9.8-1 +- Update to 3.9.8 + * Mon Aug 30 2021 Miro Hrončok - 3.9.7-1 - Update to 3.9.7 diff --git a/sources b/sources index c0e8376..59eae6d 100644 --- a/sources +++ b/sources @@ -1,2 +1,2 @@ -SHA512 (Python-3.9.7.tar.xz) = 55139776ab58a40f9e1e70613d7071d559ef9e51e32a77791422aac134322c21a49f0348c42813214b69789c589367eae43e16d4ae838a73daf37617e966b735 -SHA512 (Python-3.9.7.tar.xz.asc) = 7ff9f845f520efab3b4a0e95da3ffe055ee5777a4173a5b2cc1fd2419dc2b4faf30d1e711e372df36e34bc971ecfcde88a7cd815cfe2d8080ccb575a1ae8e101 +SHA512 (Python-3.9.8.tar.xz) = 5d5b46a242525b2e6a7f9c69c63c6d7cd985e1443a7d9b716107e75f14fef7b5c9c2e5e8a90adbbbf5f7a8b90a483d01e18c1732470e6e54b611b5aba9f99fe1 +SHA512 (Python-3.9.8.tar.xz.asc) = 1329a8e114feb010bb3618472cddd9fdea59fc38e9583002eb457e1c0cf1716bd7c0d51887e91b9eef09c3977879aa4be9909e5997be7dfdcca08ca04794bfaf From ad3f146b58ae657c6b0b323ce98ebfbb983e979d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Hrn=C4=8Diar?= Date: Thu, 18 Nov 2021 11:20:47 +0100 Subject: [PATCH 08/10] Update pip and setuptools to the latest bundled versions In previous commit, patch 00189 was updated to the latest bundled versions of pip and setuptools, but it was forgotten to update also versions in spec file. --- python3.9.spec | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/python3.9.spec b/python3.9.spec index 4c7e24f..9d240f2 100644 --- a/python3.9.spec +++ b/python3.9.spec @@ -305,7 +305,7 @@ Patch1: 00001-rpath.patch # See https://bugzilla.redhat.com/show_bug.cgi?id=556092 Patch111: 00111-no-static-lib.patch -# 00189 # ab9a031e2a429afce5c3e1777633d5305b956ea6 +# 00189 # d06cf137c00fd3907b436fdb92a8f007a7f2fb50 # Instead of bundled wheels, use our RPM packaged wheels # # We keep them in /usr/share/python-wheels @@ -317,8 +317,8 @@ Patch189: 00189-use-rpm-wheels.patch # The versions are written in Lib/ensurepip/__init__.py, this patch removes them. # When the bundled setuptools/pip wheel is updated, the patch no longer applies cleanly. # In such cases, the patch needs to be amended and the versions updated here: -%global pip_version 21.2.3 -%global setuptools_version 57.4.0 +%global pip_version 21.2.4 +%global setuptools_version 58.1.0 # 00251 # 2eabd04356402d488060bc8fe316ad13fc8a3356 # Change user install location From 23a285e10f90a29fb0d97e60e91e4cfca5287c93 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Hrn=C4=8Diar?= Date: Fri, 19 Nov 2021 08:41:46 +0100 Subject: [PATCH 09/10] Update to 3.9.9 --- python3.9.spec | 5 ++++- sources | 4 ++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/python3.9.spec b/python3.9.spec index 9d240f2..365ca9d 100644 --- a/python3.9.spec +++ b/python3.9.spec @@ -13,7 +13,7 @@ URL: https://www.python.org/ # WARNING When rebasing to a new Python version, # remember to update the python3-docs package as well -%global general_version %{pybasever}.8 +%global general_version %{pybasever}.9 #global prerel ... %global upstream_version %{general_version}%{?prerel} Version: %{general_version}%{?prerel:~%{prerel}} @@ -1783,6 +1783,9 @@ CheckPython optimized # ====================================================== %changelog +* Tue Nov 16 2021 Tomáš Hrnčiar - 3.9.9-1 +- Update to 3.9.9 + * Mon Nov 08 2021 Tomáš Hrnčiar - 3.9.8-1 - Update to 3.9.8 diff --git a/sources b/sources index 59eae6d..d7b5371 100644 --- a/sources +++ b/sources @@ -1,2 +1,2 @@ -SHA512 (Python-3.9.8.tar.xz) = 5d5b46a242525b2e6a7f9c69c63c6d7cd985e1443a7d9b716107e75f14fef7b5c9c2e5e8a90adbbbf5f7a8b90a483d01e18c1732470e6e54b611b5aba9f99fe1 -SHA512 (Python-3.9.8.tar.xz.asc) = 1329a8e114feb010bb3618472cddd9fdea59fc38e9583002eb457e1c0cf1716bd7c0d51887e91b9eef09c3977879aa4be9909e5997be7dfdcca08ca04794bfaf +SHA512 (Python-3.9.9.tar.xz) = 0ab29fb9a7ecb808bd08d84d28908d5a934e0f021853da0f7a9c94670eb30c8dbbc233d461afdb3995b0de59275ef7e1de43e82d7f848802cbd6e6e50b7b25a6 +SHA512 (Python-3.9.9.tar.xz.asc) = 84fb739c60216ab9a7a487a0ec4039a7e85c7684ef1f71d8b3bc415ff2ae284f79474103ae05385502bc2510401f8cfb33d84dccf5d0ea9a0dd62528519d935f From 26e7b720df673023a7d630d634e1052aec79ff5e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Hrn=C4=8Diar?= Date: Fri, 19 Nov 2021 14:12:25 +0100 Subject: [PATCH 10/10] Add patch to revert "bpo-1596321: Fix threading._shutdown() for the main thread" https://bodhi.fedoraproject.org/updates/FEDORA-2021-e152ce5f31 https://github.com/GrahamDumpleton/mod_wsgi/issues/730 --- ...or-the-main-thread-gh-28549-gh-28589.patch | 103 ++++++++++++++++++ python3.9.spec | 16 ++- 2 files changed, 118 insertions(+), 1 deletion(-) create mode 100644 00371-revert-bpo-1596321-fix-threading-_shutdown-for-the-main-thread-gh-28549-gh-28589.patch diff --git a/00371-revert-bpo-1596321-fix-threading-_shutdown-for-the-main-thread-gh-28549-gh-28589.patch b/00371-revert-bpo-1596321-fix-threading-_shutdown-for-the-main-thread-gh-28549-gh-28589.patch new file mode 100644 index 0000000..015cb48 --- /dev/null +++ b/00371-revert-bpo-1596321-fix-threading-_shutdown-for-the-main-thread-gh-28549-gh-28589.patch @@ -0,0 +1,103 @@ +From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Hrn=C4=8Diar?= +Date: Fri, 19 Nov 2021 13:37:16 +0100 +Subject: [PATCH] 00371: Revert "bpo-1596321: Fix threading._shutdown() for the + main thread (GH-28549) (GH-28589)" + +This reverts commit 94d19f606fa18a1c4d2faca1caf2f470a8ce6d46. It +introduced regression causing FreeIPA's tests to fail. + +For more info see: +https://bodhi.fedoraproject.org/updates/FEDORA-2021-e152ce5f31 +https://github.com/GrahamDumpleton/mod_wsgi/issues/730 +--- + Lib/test/test_threading.py | 33 --------------------------------- + Lib/threading.py | 25 ++++++++----------------- + 2 files changed, 8 insertions(+), 50 deletions(-) + +diff --git a/Lib/test/test_threading.py b/Lib/test/test_threading.py +index af480b9014..a57085b75d 100644 +--- a/Lib/test/test_threading.py ++++ b/Lib/test/test_threading.py +@@ -814,39 +814,6 @@ class ThreadTests(BaseTestCase): + threading.Thread(target=noop).start() + # Thread.join() is not called + +- def test_import_from_another_thread(self): +- # bpo-1596321: If the threading module is first import from a thread +- # different than the main thread, threading._shutdown() must handle +- # this case without logging an error at Python exit. +- code = textwrap.dedent(''' +- import _thread +- import sys +- +- event = _thread.allocate_lock() +- event.acquire() +- +- def import_threading(): +- import threading +- event.release() +- +- if 'threading' in sys.modules: +- raise Exception('threading is already imported') +- +- _thread.start_new_thread(import_threading, ()) +- +- # wait until the threading module is imported +- event.acquire() +- event.release() +- +- if 'threading' not in sys.modules: +- raise Exception('threading is not imported') +- +- # don't wait until the thread completes +- ''') +- rc, out, err = assert_python_ok("-c", code) +- self.assertEqual(out, b'') +- self.assertEqual(err, b'') +- + + class ThreadJoinOnShutdown(BaseTestCase): + +diff --git a/Lib/threading.py b/Lib/threading.py +index a3cb245ab9..ca1d6f08c4 100644 +--- a/Lib/threading.py ++++ b/Lib/threading.py +@@ -1433,29 +1433,20 @@ def _shutdown(): + + global _SHUTTING_DOWN + _SHUTTING_DOWN = True ++ # Main thread ++ tlock = _main_thread._tstate_lock ++ # The main thread isn't finished yet, so its thread state lock can't have ++ # been released. ++ assert tlock is not None ++ assert tlock.locked() ++ tlock.release() ++ _main_thread._stop() + + # Call registered threading atexit functions before threads are joined. + # Order is reversed, similar to atexit. + for atexit_call in reversed(_threading_atexits): + atexit_call() + +- # Main thread +- if _main_thread.ident == get_ident(): +- tlock = _main_thread._tstate_lock +- # The main thread isn't finished yet, so its thread state lock can't +- # have been released. +- assert tlock is not None +- assert tlock.locked() +- tlock.release() +- _main_thread._stop() +- else: +- # bpo-1596321: _shutdown() must be called in the main thread. +- # If the threading module was not imported by the main thread, +- # _main_thread is the thread which imported the threading module. +- # In this case, ignore _main_thread, similar behavior than for threads +- # spawned by C libraries or using _thread.start_new_thread(). +- pass +- + # Join all non-deamon threads + while True: + with _shutdown_locks_lock: diff --git a/python3.9.spec b/python3.9.spec index 365ca9d..57297c2 100644 --- a/python3.9.spec +++ b/python3.9.spec @@ -17,7 +17,7 @@ URL: https://www.python.org/ #global prerel ... %global upstream_version %{general_version}%{?prerel} Version: %{general_version}%{?prerel:~%{prerel}} -Release: 1%{?dist} +Release: 2%{?dist} License: Python @@ -370,6 +370,17 @@ Patch328: 00328-pyc-timestamp-invalidation-mode.patch # a nightmare because it's basically a binary file. Patch353: 00353-architecture-names-upstream-downstream.patch +# 00371 # 1fc313929648e9b543542de09f59c55e175ac45a +# Revert "bpo-1596321: Fix threading._shutdown() for the main thread (GH-28549) (GH-28589)" +# +# This reverts commit 94d19f606fa18a1c4d2faca1caf2f470a8ce6d46. It +# introduced regression causing FreeIPA's tests to fail. +# +# For more info see: +# https://bodhi.fedoraproject.org/updates/FEDORA-2021-e152ce5f31 +# https://github.com/GrahamDumpleton/mod_wsgi/issues/730 +Patch371: 00371-revert-bpo-1596321-fix-threading-_shutdown-for-the-main-thread-gh-28549-gh-28589.patch + # (New patches go here ^^^) # # When adding new patches to "python" and "python3" in Fedora, EL, etc., @@ -1783,6 +1794,9 @@ CheckPython optimized # ====================================================== %changelog +* Fri Nov 19 2021 Tomáš Hrnčiar - 3.9.9-2 +- Add patch to revert "bpo-1596321: Fix threading._shutdown() for the main thread" + * Tue Nov 16 2021 Tomáš Hrnčiar - 3.9.9-1 - Update to 3.9.9