Skip to content

gh-161564: Remove test_type_annotations from lazy_imports_all_exclude.txt - #161566

Open
sobolevn wants to merge 4 commits into
python:mainfrom
sobolevn:issue-161564
Open

sobolevn wants to merge 4 commits into
python:mainfrom
sobolevn:issue-161564

Conversation

@sobolevn

@sobolevn sobolevn commented Nov 7, 2026 •

Copy link
Copy Markdown
Member

Since different modes have different module loading semantics, we must assert them separately.

Comment thread Lib/test/test_type_annotations.py Resolved
{"v1": int, "v2": int},
)
self.assertEqual(partialexe.b.annos, {"v1": int})
# Module execution semantics differ based on the lazy imports mode:

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.

This still doesn't really say why it differs. My default assumption is that it's a bug when behavior differs depending on the lazy import mode. Maybe it's an unavoidable bug that nobody will really run into and it's fine to ignore, but we should at least investigate.

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