]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
gh-118761: Add helper to ensure that lazy imports are actually lazy (#132614)
authorJelle Zijlstra <jelle.zijlstra@gmail.com>
Thu, 17 Apr 2025 03:46:36 +0000 (20:46 -0700)
committerGitHub <noreply@github.com>
Thu, 17 Apr 2025 03:46:36 +0000 (03:46 +0000)
commit39ee468e092eed659bfc2a4e0ce02572e0d81de0
tree839e4b3aabdca4f8855b94c593e28d60b1689edc
parentb530e174a3f870f0795200fee197a46e8bbfd0e8
gh-118761: Add helper to ensure that lazy imports are actually lazy (#132614)

This ensures that if we jump through some hoops to make sure something is imported
lazily, we don't regress on importing it.

I recently already accidentally made typing import warnings and annotationlib eagerly.

Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
Lib/test/support/import_helper.py
Lib/test/test_annotationlib.py
Lib/test/test_typing.py