Skip to content

fix crash with variadic tuple arguments to generic type #19705

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

randolf-scholz
Copy link
Contributor

Fixes #19704

@randolf-scholz randolf-scholz marked this pull request as draft August 21, 2025 09:57

This comment has been minimized.

This comment has been minimized.

@randolf-scholz randolf-scholz marked this pull request as ready for review August 24, 2025 09:52

tuple[*tuple[int, ...], *tuple[int, ...]] # E: More than one Unpack in a type is not allowed
b: tuple[*tuple[int, ...], *tuple[int, ...]] # E: More than one Unpack in a type is not allowed
tuple[*tuple[int, ...], *tuple[int, ...]] # E: More than one variable Unpack in a type is not allowed
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Maybe "unbounded" instead of variable? Not sure that the best word is here....

Copy link
Contributor

According to mypy_primer, this change doesn't affect type check results on a corpus of open source code. ✅

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

mypy crashes when passing multiple variadic tuples
1 participant