Commits

Henrique Romano committed 1f357ec

name should be optional when creating Reporter instances, also remove unused import

Comments (0)

Files changed (1)

djangotriager/reporter.py

 import logging
 
 class Reporter(object):
-    def __init__(self, name):
+    def __init__(self, name=""):
         self._logger = logging.Logger(name, logging.DEBUG)
         formatter = logging.Formatter("%(name)s - %(levelname)s - %(message)s")
         self._buffer = StringIO()
-        import sys
         handler = logging.StreamHandler(self._buffer)
         handler.setFormatter(formatter)
         self._logger.addHandler(handler)