In #Python >= 3.8, this code raises "TypeError: Cannot inherit from plain Generic":
class Foo(typing.Generic): pass
but this one works:
class Protocol(typing.Generic): pass
@val that's surprising, is it checking the name?
@bram Yes. https://github.com/python/cpython/blob/master/Lib/typing.py#L958
@val that's surprising but I can understand why
This is a mastodon instance for social justice activists, LGBTQIA+ people, and activists in general