Skip to content

Commit

Permalink
Add NullHandler to logging instance
Browse files Browse the repository at this point in the history
When no logging is configured, the absence of a logging handler makes
python output a warning to stdout. Adding a NullHandler resolves this
issue.

Closes #15
  • Loading branch information
ingwinlu committed Oct 1, 2015
1 parent 6efa84b commit 094ebfa
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions twitch/logging.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
import logging

log = logging.getLogger('twitch')
log.addHandler(logging.NullHandler())


def deprecation_warning(logger, old, new):
Expand Down

0 comments on commit 094ebfa

Please sign in to comment.