Skip to content
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

Prevent double logging in setup_logger #172

Merged
merged 1 commit into from
Jul 14, 2022
Merged

Prevent double logging in setup_logger #172

merged 1 commit into from
Jul 14, 2022

Conversation

psrok1
Copy link
Member

@psrok1 psrok1 commented Jul 13, 2022

Sometimes double logging on stdout appears. This PR targets the main possible causes:

  • setup_logger called twice, so handlers are duplicated
  • propagate=False in case basicConfig was called and StreamHandler is set on root logger level

In addition, fixed doc comments a bit.

@psrok1 psrok1 requested a review from nazywam July 13, 2022 10:43
@psrok1 psrok1 merged commit 96e35f1 into master Jul 14, 2022
@psrok1 psrok1 deleted the fix/double-logging branch July 14, 2022 12:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants