#87 [F35] Update to 3.10.1
Merged 2 years ago by churchyard. Opened 2 years ago by thrnciar.
rpms/ thrnciar/python3.10 f35-update-to-3.10.1  into  f35

file modified
+1 -1
@@ -9,7 +9,7 @@ 

   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):

@@ -19,7 +19,7 @@ 

   2 files changed, 4 insertions(+), 1 deletion(-)

  

  diff --git a/Lib/py_compile.py b/Lib/py_compile.py

- index 0f9b59025c..59dc3fe50b 100644

+ index 388614e51b..db52725016 100644

  --- a/Lib/py_compile.py

  +++ b/Lib/py_compile.py

  @@ -70,7 +70,8 @@ class PycInvalidationMode(enum.Enum):

@@ -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?= <thrnciar@redhat.com>

+ Date: Tue, 7 Dec 2021 14:41:59 +0100

+ Subject: [PATCH] 00371: Revert "bpo-1596321: Fix threading._shutdown() for the

+  main thread (GH-28549) (GH-28589)"

+ 

+ This reverts commit 38c67738c64304928c68d5c2bd78bbb01d979b94. 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 c54806e594..c51de6f4b8 100644

+ --- a/Lib/test/test_threading.py

+ +++ b/Lib/test/test_threading.py

+ @@ -928,39 +928,6 @@ def test_debug_deprecation(self):

+                 b'is deprecated and will be removed in Python 3.12')

+          self.assertIn(msg, err)

+  

+ -    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 2d89742913..928b3f715d 100644

+ --- a/Lib/threading.py

+ +++ b/Lib/threading.py

+ @@ -1523,29 +1523,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:

file modified
+17 -3
@@ -13,7 +13,7 @@ 

  

  #  WARNING  When rebasing to a new Python version,

  #           remember to update the python3-docs package as well

- %global general_version %{pybasever}.0

+ %global general_version %{pybasever}.1

  #global prerel ...

  %global upstream_version %{general_version}%{?prerel}

  Version: %{general_version}%{?prerel:~%{prerel}}
@@ -68,8 +68,8 @@ 

  # If the rpmwheels condition is disabled, we use the bundled wheel packages

  # from Python with the versions below.

  # This needs to be manually updated when we update Python.

- %global pip_version 21.2.3

- %global setuptools_version 57.4.0

+ %global pip_version 21.2.4

+ %global setuptools_version 58.1.0

  

  # Expensive optimizations (mainly, profile-guided optimizations)

  %bcond_without optimizations
@@ -292,6 +292,17 @@ 

  # Ideally, we should talk to upstream and explain why we don't want this

  Patch328: 00328-pyc-timestamp-invalidation-mode.patch

  

+ # 00371 # c1754d9c2750f89cb702e1b63a99201f5f7cff00

+ # Revert "bpo-1596321: Fix threading._shutdown() for the main thread (GH-28549) (GH-28589)"

+ #

+ # This reverts commit 38c67738c64304928c68d5c2bd78bbb01d979b94. 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.,
@@ -1581,6 +1592,9 @@ 

  # ======================================================

  

  %changelog

+ * Tue Dec 07 2021 Tomáš Hrnčiar <thrnciar@redhat.com> - 3.10.1-1

+ - Update to 3.10.1

+ 

  * Mon Oct 04 2021 Miro Hrončok <mhroncok@redhat.com> - 3.10.0-1

  - Update to 3.10.0 final

  

file modified
+2 -2
@@ -1,2 +1,2 @@ 

- SHA512 (Python-3.10.0.tar.xz) = 82b2729afc7d72a80882f199970667dce7d971a2e5ecfe6cf84f7b68612ab2caf6ed6d7a8cb81f24ea85cb0816464bb2e8b2e6884eda62fa40742edc674193bd

- SHA512 (Python-3.10.0.tar.xz.asc) = 67236e02bc49da1423717cb54216b745f613ba2fc4b372a4aa15a36ab15fe69d9b9087070382957d480df7576d13056caedcd979fb56531799a1190b822f673d

+ SHA512 (Python-3.10.1.tar.xz) = 1c559e33f1252e51bafb941c380de16f142c0735858363c84cb8dbed6767843de3af126889c2826ffb94bd4777d7cdfc31040301c8c74de56af52b80b1aa9e76

+ SHA512 (Python-3.10.1.tar.xz.asc) = 645d5f40e6e80a590923a48763f20dea7da3f3eea5825bb79e08618d81d1b8eee0ddee2b57503321a584280536e0671e4913e5ad450568fbbb44509c01d3907d

file modified
+5 -1
@@ -21,6 +21,9 @@ 

      - smoke:

          dir: python/smoke

          run: VERSION=3.10 ./venv.sh

+     - smoke_virtualenv:

+         dir: python/smoke

+         run: VERSION=3.10 METHOD=virtualenv ./venv.sh

      - debugsmoke:

          dir: python/smoke

          run: PYTHON=python3-debug TOX=false VERSION=3.10 ./venv.sh
@@ -44,7 +47,8 @@ 

      - python3-devel  # for extension building in venv and selftest

      - python3-tkinter  # for selftest

      - python3-test  # for selftest

-     - python3-tox  # for venv tests

+     - tox  # for venv tests

+     - virtualenv  # for virtualenv tests

      - glibc-all-langpacks # for locale tests

      - marshalparser  # for testing compatibility (magic numbers) with marshalparser

      - rpm  # for debugging

no initial comment

Build failed. More information on how to proceed and troubleshoot errors available at https://fedoraproject.org/wiki/Zuul-based-ci

The setuptools/pip version bump that is present in rawhide is not present here.

3 new commits added

  • Update to 3.10.1
  • Fedora CI: Also test virtualenv
  • Cosmetic CI config change: Use the new tox package name
2 years ago

Build succeeded.

@adamwill Could you please run the FreeIPA OpenQA tests for the scratch build generated here?

@churchyard sure! x86_64, ppc64le. We're not set up to run the updates tests on aarch64 because the workers don't have sufficient capacity...

openQA tests all passed, looks good.

Pull-Request has been merged by churchyard

2 years ago