FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

gh-118761: Add helper to ensure that lazy imports are actually lazy by JelleZijlstra · Pull Request #132614 · python/cpython · GitHub

/ cpython Public

gh-118761: Add helper to ensure that lazy imports are actually lazy - #132614

Merged
JelleZijlstra merged 2 commits into
python:mainfrom
JelleZijlstra:runtimedocs
Apr 17, 2025
Merged

gh-118761: Add helper to ensure that lazy imports are actually lazy#132614
JelleZijlstra merged 2 commits into
python:mainfrom
JelleZijlstra:runtimedocs

Conversation

JelleZijlstra commented Apr 16, 2025
edited by bedevere-app Bot
Loading

Copy link
Copy Markdown
Member

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.

…lazy

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.
Comment thread Lib/test/test_typing.py
"inspect",
"re",
"contextlib",
# "annotationlib", # TODO

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

#132596 will fix this

AA-Turner left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

Good idea!

Comment thread Lib/test/support/import_helper.py Outdated
Comment thread Lib/test/support/import_helper.py Outdated
Comment thread Lib/test/test_annotationlib.py Outdated
Comment thread Lib/test/test_typing.py Outdated
Comment thread Lib/test/test_typing.py Outdated
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants


Back | FazBrowse Home | New Git URL