-
-
Notifications
You must be signed in to change notification settings - Fork 280
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Don't allow passing in loguru #420
Comments
Hi there. As per the type-hints in the source code of tenacity/tenacity/before_sleep.py Lines 31 to 36 in 3100582
Consequently, users should not expect In this situation, the most appropriate workaround is for users to define a standard |
Loguru is not api compatible with standard logging despite efforts in #294, so it may be best to raise an error or wrap the loguru logger with a standard logger when doing this
As it can cause a
KeyError
due to thisHere's a wrapping approach which may be the best thing for people to setup in accordance with their own logging needs. Not sure if @Delgan has a better approach though.
The text was updated successfully, but these errors were encountered: