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

Fix/default log handler #248

Merged
merged 3 commits into from
May 15, 2018
Merged

Fix/default log handler #248

merged 3 commits into from
May 15, 2018

Conversation

PLNech
Copy link
Member

@PLNech PLNech commented Mar 28, 2018

Following a Support ticket:

When we are attempting to reindex our account, we are receiving this response (using Algolia' django project)
No handlers could be found for logger "algoliasearch_django.models"

Indeed, we didn't follow the recommended way to Configure logging for a library:

In addition to documenting how a library uses logging, a good way to configure library logging so that it does not cause a spurious message is to add a handler which does nothing.

This PR implements such a NullHandler. I'm not using the NullHandler class as it's only available with python > 3.1.

@PLNech PLNech merged commit bf1072d into master May 15, 2018
@PLNech PLNech deleted the fix/DefaultLogHandler branch May 15, 2018 12:47
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.

1 participant