Skip to content

Fix various TypeAlias issues - #8248

Merged
hauntsaninja merged 2 commits into
masterfrom
aliases
Jul 7, 2022
Merged

hauntsaninja merged 2 commits into
masterfrom
aliases

Conversation

@AlexWaygood

Copy link
Copy Markdown
Member

@hauntsaninja hauntsaninja left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

The reasoning behind removing the conditional type alias annotations isn't clear to me

@AlexWaygood

Copy link
Copy Markdown
Member Author

The reasoning behind removing the conditional type alias annotations isn't clear to me

Yeah, tbh I'm slightly unsure for those ones about whether it's better to consider them as type aliases or variable aliases. Happy to revert those changes if you think it's better the way it is; don't really have a strong opinion there.

@github-actions

This comment has been minimized.

@AlexWaygood
AlexWaygood requested a review from hauntsaninja July 6, 2022 20:26
@github-actions

github-actions Bot commented Jul 6, 2022

Copy link
Copy Markdown
Contributor

According to mypy_primer, this change has no effect on the checked open source code. 🤖🎉

@hauntsaninja hauntsaninja left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Thanks! These are simple and uncontroversial. I don't have a strong opinion on the removed ones, so if there is some benefit feel free to open another PR.

@hauntsaninja
hauntsaninja merged commit 9ccf458 into master Jul 7, 2022
@hauntsaninja
hauntsaninja deleted the aliases branch July 7, 2022 12:18
@AlexWaygood

Copy link
Copy Markdown
Member Author

Thanks! These are simple and uncontroversial. I don't have a strong opinion on the removed ones, so if there is some benefit feel free to open another PR.

I thought there were some benefits, but I was playing around on mypy playground and couldn't find any reason to make the change in terms of actually improving the stub. It reduces the hits from PyCQA/flake8-pyi#240, but I think that that approach probably isn't viable anyway, so I don't think that's a good reason to make those changes ¯\_(ツ)_/¯

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.

2 participants