Skip to content
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

bpo-40185: Refactor typing.NamedTuple #19371

Merged

Conversation

serhiy-storchaka
Copy link
Member

@serhiy-storchaka serhiy-storchaka commented Apr 4, 2020

Copy link
Member

@ilevkivskyi ilevkivskyi left a comment

Choose a reason for hiding this comment

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

I like this change, because people sometimes erroneously percept NamedTuple as a "normal" class. I would however double-check with Guido if he is also OK with this.

pass
with self.assertRaises(TypeError):
class X(NamedTuple, A):
x: int
Copy link
Member

Choose a reason for hiding this comment

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

Looks like a bad merge/rebase, you already added this test in a different PR.

Copy link
Member

@gvanrossum gvanrossum left a comment

Choose a reason for hiding this comment

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

A work of art!

@serhiy-storchaka serhiy-storchaka merged commit a2ec069 into python:master Apr 8, 2020
@serhiy-storchaka serhiy-storchaka deleted the refactor-typing-namedtuple branch April 8, 2020 07:59
@serhiy-storchaka
Copy link
Member Author

Thanks. 😊

juliusgeo added a commit to juliusgeo/cpython that referenced this pull request Mar 4, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
skip news type-feature A feature request or enhancement
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants