Readd timestamps to the logs
This commit is contained in:
parent
50344772eb
commit
56ecabbd78
@ -38,6 +38,9 @@ def set_level(level):
|
|||||||
logging.getLogger('').setLevel(levels[level])
|
logging.getLogger('').setLevel(levels[level])
|
||||||
|
|
||||||
def start(log_filename=None):
|
def start(log_filename=None):
|
||||||
|
logging.basicConfig(level=logging.WARNING,
|
||||||
|
format="%(created)f %(levelname)s %(message)s")
|
||||||
|
|
||||||
if os.environ.has_key('SUGAR_LOGGER_LEVEL'):
|
if os.environ.has_key('SUGAR_LOGGER_LEVEL'):
|
||||||
set_level(os.environ['SUGAR_LOGGER_LEVEL'])
|
set_level(os.environ['SUGAR_LOGGER_LEVEL'])
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user