On Wed, Feb 24, 2021 at 5:58 PM Jim J. Jewett <jimjjew...@gmail.com> wrote:
> If it (compatible __new__ and __init__) needs to be checked at definition > time, just try create an instance passing the same arguments you would pass > to the base class. If the creation it doesn't raise an exception, that is > good enough. > User code can do that, the interpreter should not use such heuristics. > This isn't about theoretical type safety against malice; it is about > defining the minimal protocol for an ExceptionGrouping that has to be > supported by someone who wants something other than the default flavor. > You still haven't shown a use case for wanting to subclass ExceptionGroup. It's easy to allow this later if there's a valid use case (it wouldn't require a PEP, just a well-reasoned use case). But if we allow it now and in the future we discover it causes subtle bugs, it would be difficult to roll back (requiring deprecation over several releases). Why would you want a different flavor of ExceptionGroup? -- --Guido van Rossum (python.org/~guido) *Pronouns: he/him **(why is my pronoun here?)* <http://feministing.com/2015/02/03/how-using-they-as-a-singular-pronoun-can-change-the-world/>
_______________________________________________ Python-Dev mailing list -- python-dev@python.org To unsubscribe send an email to python-dev-le...@python.org https://mail.python.org/mailman3/lists/python-dev.python.org/ Message archived at https://mail.python.org/archives/list/python-dev@python.org/message/SMEJMIMSIMWOXW47KDMRL3POCRHNTSXC/ Code of Conduct: http://python.org/psf/codeofconduct/