Make .catch()
context manager async compatible
#1084
Labels
enhancement
Improvement to an already existing feature
.catch()
context manager async compatible
#1084
Hi,
First, thanks for a lot for loguru :)
I have a piece of code like this:
In python, it's possible to chain context managers:
But I don't think it's possible to mix async and sync context managers.
So I wonder if we could make the class
Catcher
async compatible? I think that it would require implementing__aenter__
and__aexit__
This feature would allow this:
Thanks
The text was updated successfully, but these errors were encountered: