cpython
cpython copied to clipboard
gh-125900: Clean-up logic around immortalization in free-threading
- Remove
@suppress_immortalizationdecorator - Make suppression flag per-thread instead of per-interpreter
- Suppress immortalization in
eval()to avoid refleaks in three tests (test_datetime.test_roundtrip, test_logging.test_config8_ok, and test_random.test_after_fork). - frozenset() is constant, but not a singleton. When run multiple times, the test could fail due to constant interning.
- Issue: gh-125900