You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Warnings and errors specific to the C implementation of the warnings module #122255
New deprecation warnings about missing or inconsistent __spec__.loader and __loader__ introduced in #86298 are emitted only for the C implementation of the warnings module. Existing errors (AttributeError or ValueError) are also only raised for the C implementation of the warnings module. See tests added in #122227.
I believe that before turning the deprecation warnings into errors, we should add warnings for the Python implementation.
Activity
gh-122255: Add black box tests in test_warnings (GH-122227)
pythongh-122255: Add black box tests in test_warnings (pythonGH-122227)
pythongh-122255: Add black box tests in test_warnings (pythonGH-122227)
pythongh-122255: Synchronize warnings in C and Python implementations…
[3.13] gh-122255: Add black box tests in test_warnings (GH-122227) (G…
serhiy-storchaka commentedon Aug 14, 2024
Tests are failed for this change, and I think this is because it exposes a flaw in the current code. Opened #123011.
[3.12] gh-122255: Add black box tests in test_warnings (GH-122227) (G…
pythongh-122255: Add black box tests in test_warnings (pythonGH-122227)
serhiy-storchaka commentedon Nov 9, 2025
Note also that
__spec__is set to None for the__main__module. If__loader__is deprecated, what should be used for the__main__module?gh-122255: Synchronize warnings in C and Python implementations of th…
pythongh-122255: Synchronize warnings in C and Python implementations…