File size: 208 Bytes
60f5111
 
 
 
 
 
 
1
2
3
4
5
6
7
8
class MyExceptionGroup(BaseExceptionGroup):
    pass

eg = MyExceptionGroup("eg", [ValueError(1), KeyboardInterrupt(2)])
match, rest = eg.split(ValueError)
print(f'match: {match!r}')
print(f'rest: {rest!r}')