summaryrefslogtreecommitdiffstats
path: root/Misc/NEWS.d
diff options
context:
space:
mode:
authoralbanD <desmaison.alban@gmail.com>2023-08-30 17:07:41 (GMT)
committerGitHub <noreply@github.com>2023-08-30 17:07:41 (GMT)
commitadd8d45cbe46581b9748909fbbf60fdc8ee8f71e (patch)
treeeeaffda1c22e7c99be3c23a22d04d6e2866ebd5f /Misc/NEWS.d
parent2a3926fa51b7264787d5988abf083d8c4328f4ad (diff)
downloadcpython-add8d45cbe46581b9748909fbbf60fdc8ee8f71e.zip
cpython-add8d45cbe46581b9748909fbbf60fdc8ee8f71e.tar.gz
cpython-add8d45cbe46581b9748909fbbf60fdc8ee8f71e.tar.bz2
gh-108520: Fix bad fork detection in nested multiprocessing use case (#108568)
gh-107275 introduced a regression where a SemLock would fail being passed along nested child processes, as the `is_fork_ctx` attribute would be left missing after the first deserialization. --------- Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com> Co-authored-by: Antoine Pitrou <pitrou@free.fr>
Diffstat (limited to 'Misc/NEWS.d')
-rw-r--r--Misc/NEWS.d/next/Core and Builtins/2023-08-30-15-41-47.gh-issue-108520.u0ZGP_.rst3
1 files changed, 3 insertions, 0 deletions
diff --git a/Misc/NEWS.d/next/Core and Builtins/2023-08-30-15-41-47.gh-issue-108520.u0ZGP_.rst b/Misc/NEWS.d/next/Core and Builtins/2023-08-30-15-41-47.gh-issue-108520.u0ZGP_.rst
new file mode 100644
index 0000000..44131fb
--- /dev/null
+++ b/Misc/NEWS.d/next/Core and Builtins/2023-08-30-15-41-47.gh-issue-108520.u0ZGP_.rst
@@ -0,0 +1,3 @@
+Fix :meth:`multiprocessing.synchronize.SemLock.__setstate__` to properly initialize :attr:`multiprocessing.synchronize.SemLock._is_fork_ctx`. This fixes a regression when passing a SemLock accross nested processes.
+
+Rename :attr:`multiprocessing.synchronize.SemLock.is_fork_ctx` to :attr:`multiprocessing.synchronize.SemLock._is_fork_ctx` to avoid exposing it as public API.