Skip to content

gh-155835: fix digest_size data race on BLAKE-2 objects - #155839

Merged
picnixz merged 5 commits into
python:mainfrom
picnixz:meta/crypto/c/36/blake2-hash-critical-sections-155835
Sep 6, 2026
Merged

gh-155835: fix digest_size data race on BLAKE-2 objects#155839
picnixz merged 5 commits into
python:mainfrom
picnixz:meta/crypto/c/36/blake2-hash-critical-sections-155835

Conversation

@picnixz

@picnixzpicnixz commented Aug 15, 2026

Copy link
Copy Markdown
Member

@picnixz
picnixz requested a review from gpshead as a code ownerAugust 15, 2026 11:20
@picnixzpicnixz added needs backport to 3.13 bugs and security fixes needs backport to 3.14 bugs and security fixes needs backport to 3.15 pre-release feature fixes, bugs and security fixes awaiting core review and removed awaiting core review needs backport to 3.13 bugs and security fixes labels Aug 15, 2026
@picnixz

Copy link
Copy Markdown
MemberAuthor

Note to myself: I should add tests. I forgot about that and will do it tomorrow probably.

Comment threadLib/test/test_hashlib.py Outdated
@picnixz
picnixz merged commit 878b5e2 into python:mainSep 6, 2026
54 checks passed
@picnixz
picnixz deleted the meta/crypto/c/36/blake2-hash-critical-sections-155835 branch September 6, 2026 16:49
@miss-islington-app

Copy link
Copy Markdown

Thanks @picnixz for the PR 🌮🎉.. I'm working now to backport this PR to: 3.14, 3.15.
🐍🍒⛏🤖 I'm not a witch! I'm not a witch!

@miss-islington-app

Copy link
Copy Markdown

Sorry, @picnixz, I could not cleanly backport this to 3.15 due to a conflict.
Please backport using cherry_picker on command line.

cherry_picker 878b5e256aa40c45e12a0cd5c63f8a249f7c3704 3.15

@miss-islington-app

Copy link
Copy Markdown

Sorry, @picnixz, I could not cleanly backport this to 3.14 due to a conflict.
Please backport using cherry_picker on command line.

cherry_picker 878b5e256aa40c45e12a0cd5c63f8a249f7c3704 3.14

@bedevere-bot

Copy link
Copy Markdown

⚠️⚠️⚠️ Buildbot failure ⚠️⚠️⚠️

Hi! The buildbot AMD64 Windows PGO Tailcall 3.x (tier-1) has failed when building commit 878b5e2.

What do you need to do:

  1. Don't panic.
  2. Check the buildbot page in the devguide if you don't know what the buildbots are or how they work.
  3. Go to the page of the buildbot that failed (https://buildbot.python.org/#/builders/1870/builds/1300) and take a look at the build logs.
  4. Check if the failure is related to this commit (878b5e2) or if it is a false positive.
  5. If the failure is related to this commit, please, reflect that on the issue and make a new Pull Request with a fix.

You can take a look at the buildbot page here:

https://buildbot.python.org/#/builders/1870/builds/1300

Failed tests:

  • test.test_asyncio.test_sslproto
  • test_regrtest

Failed subtests:

  • test_shutdown_corrupted_ssl_sends_close_notify - test.test_asyncio.test_sslproto.SelectorStartTLSTests.test_shutdown_corrupted_ssl_sends_close_notify
  • test_multiprocessing_timeout - test.test_regrtest.ArgsTestCase.test_multiprocessing_timeout

Summary of the results of the build (if available):

==

Click to see traceback logs
Traceback (most recent call last):
File "C:\bbarea\3.x.itamaro-win64-srv-22-aws.tailcall.pgo\build\Lib\threading.py", line 1218, in _bootstrap_innerself._context.run(self.run)
~~~~~~~~~~~~~~~~~^^^^^^^^^^
File "C:\bbarea\3.x.itamaro-win64-srv-22-aws.tailcall.pgo\build\Lib\test\test_asyncio\functional.py", line 227, in runself._run()
~~~~~~~~~^^
File "C:\bbarea\3.x.itamaro-win64-srv-22-aws.tailcall.pgo\build\Lib\test\test_asyncio\functional.py", line 261, in _runself._test._abort_socket_test(ex)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^
File "C:\bbarea\3.x.itamaro-win64-srv-22-aws.tailcall.pgo\build\Lib\test\test_asyncio\functional.py", line 110, in _abort_socket_testself.fail(ex)
~~~~~~~~~^^^^
File "C:\bbarea\3.x.itamaro-win64-srv-22-aws.tailcall.pgo\build\Lib\unittest\case.py", line 772, in failraiseself.failureException(msg)
AssertionError: [WinError 10054] An existing connection was forcibly closed by the remote host
ERROR
Traceback (most recent call last):
File "C:\bbarea\3.x.itamaro-win64-srv-22-aws.tailcall.pgo\build\Lib\test\test_regrtest.py", line 1939, in test_multiprocessing_timeoutself.assertRegex(output,
~~~~~~~~~~~~~~~~^^^^^^^^
re.compile('%s timed out'% testname, re.MULTILINE))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^AssertionError: Regex didn't match: 'test_regrtest_noop21 timed out' not found in 'Using random seed: 2884225283\n0:00:00 mem: 23.7 MiB Run 1 test in parallel using 1 worker process (timeout: 1.0 sec, worker timeout: 1.5 sec)\n0:00:01 mem: 24.4 MiB [1/1/1] test_regrtest_noop21 worker non-zero exit code (Exit code 1)\nTimeout (0:00:01)!\nThread 0x00000e68 (most recent call first):\n File "<frozen importlib._bootstrap_external>", line ??? in _path_stat\n <invalid frame>\n\n== Tests result: FAILURE ==\n\n1 test failed:\n test_regrtest_noop21\n\nTotal duration: 1.8 sec\nTotal tests: run=0\nTotal test files: run=1/1 failed=1\nResult: FAILURE\n'
Traceback (most recent call last):
File "C:\bbarea\3.x.itamaro-win64-srv-22-aws.tailcall.pgo\build\Lib\test\test_asyncio\test_sslproto.py", line 950, in test_shutdown_corrupted_ssl_sends_close_notifyself.loop.run_until_complete(client(srv.addr))
~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^
File "C:\bbarea\3.x.itamaro-win64-srv-22-aws.tailcall.pgo\build\Lib\asyncio\base_events.py", line 723, in run_until_completeraiseRuntimeError('Event loop stopped before Future completed.')
RuntimeError: Event loop stopped before Future completed.
Traceback (most recent call last):
File "C:\bbarea\3.x.itamaro-win64-srv-22-aws.tailcall.pgo\build\Lib\test\test_asyncio\functional.py", line 255, in _runself._handle_client(conn)
~~~~~~~~~~~~~~~~~~~^^^^^^
File "C:\bbarea\3.x.itamaro-win64-srv-22-aws.tailcall.pgo\build\Lib\test\test_asyncio\functional.py", line 264, in _handle_clientself._prog(TestSocketWrapper(sock))
~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\bbarea\3.x.itamaro-win64-srv-22-aws.tailcall.pgo\build\Lib\test\test_asyncio\test_sslproto.py", line 920, in server
sock.unwrap()
~~~~~~~~~~~^^
File "C:\bbarea\3.x.itamaro-win64-srv-22-aws.tailcall.pgo\build\Lib\ssl.py", line 1402, in unwrap
s =self._sslobj.shutdown()
ConnectionResetError: [WinError 10054] An existing connection was forcibly closed by the remote host

Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

needs backport to 3.14bugs and security fixesneeds backport to 3.15pre-release feature fixes, bugs and security fixes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

@picnixz@bedevere-bot