cpython/Lib/importlib
Miss Islington (bot) 7b91b9001a
[3.12] gh-114763: Protect lazy loading modules from attribute access races (GH-114781) (GH-115870)
gh-114763: Protect lazy loading modules from attribute access races (GH-114781)

Setting the __class__ attribute of a lazy-loading module to ModuleType enables other threads to attempt to access attributes before the loading is complete. Now that is protected by a lock.
(cherry picked from commit 200271c61d)

Co-authored-by: Chris Markiewicz <effigies@gmail.com>
2024-02-26 20:43:44 +00:00
..
metadata
resources [3.12] Add missed stream argument (GH-111775) (#115716) 2024-02-20 11:36:55 -05:00
__init__.py
_abc.py
_bootstrap.py [3.12] gh-112414: Fix AttributeError when calling repr() on a namespace package imported with a custom loader (GH-112425) (#112440) 2023-11-27 08:53:57 +00:00
_bootstrap_external.py [3.12] gh-112983: Add the known magic value of 3495 for Python 3.11 bytecode (GH-112985) (#113023) 2023-12-12 18:24:28 +00:00
abc.py
machinery.py
readers.py
simple.py
util.py [3.12] gh-114763: Protect lazy loading modules from attribute access races (GH-114781) (GH-115870) 2024-02-26 20:43:44 +00:00