the.bay.news

_ProtocolMeta: why? Can it be removed?

Discussions on Python.org
_ProtocolMeta: why? Can it be removed?
Having a look at typing.Protocol, this seems to depend on a metatype _ProtocolMeta. From the main branch of the CPython repository, this is what it’s reported: class _ProtocolMeta(ABCMeta): # This metaclass is somewhat unfortunate, # but is necessary for several reasons... I haven’t looked too far in depth (or rather I did not search thoroughly) but: what are these reasons exactly? Up to Python 3.12 (I think), that comment was actually different: class _ProtocolMeta(ABCMeta): # T...

0 comments

Sign in to join the discussion — your thebay.events account works here.

No comments yet.