Closed
Description
In [6]: @runtime_checkable
...: class BaseBadge(Protocol):
...: def __init__(self) -> None: ...
In [7]: BaseBadge.__init__
Out[7]: <function typing._no_init_or_replace_init(self, *args, **kwargs)>
This behaviour is not consistent with python 3.11
>>> from typing import *
>>> @runtime_checkable
... class BaseBadge(Protocol):
... def __init__(self) -> None: ...
...
>>> BaseBadge.__init__
<function BaseBadge.__init__ at 0x104f249a0>
This may have made me slightly concerned I was loosing my sanity in a subclass today 😀
Metadata
Metadata
Assignees
Labels
No labels