https://github.com/python/cpython/commit/9346e22dd064b8636a77c302648b322f354bdb30
commit: 9346e22dd064b8636a77c302648b322f354bdb30
branch: main
author: Satyam Kumar Verman <[email protected]>
committer: rhettinger <[email protected]>
date: 2025-11-24T14:36:09Z
summary:
gh-141831: Document behavior of functools.lru_cache with concurrent access
(gh-141869)
files:
M Doc/library/functools.rst
diff --git a/Doc/library/functools.rst b/Doc/library/functools.rst
index 97136b234084fc..221c0712c7c96a 100644
--- a/Doc/library/functools.rst
+++ b/Doc/library/functools.rst
@@ -57,6 +57,10 @@ The :mod:`functools` module defines the following functions:
another thread makes an additional call before the initial call has been
completed and cached.
+ Call-once behavior is not guaranteed because locks are not held during the
+ function call. Potentially another call with the same arguments could
+ occur while the first call is still running.
+
.. versionadded:: 3.9
_______________________________________________
Python-checkins mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://mail.python.org/mailman3//lists/python-checkins.python.org
Member address: [email protected]