mirror of
https://github.com/MCV-Software/TWBlue.git
synced 2025-04-20 01:21:45 -04:00
#148: Don't leak data in logs.
This commit is contained in:
parent
f640556be6
commit
7a5c3a4e7b
@ -3,6 +3,7 @@ import logging
|
||||
from logging.handlers import RotatingFileHandler
|
||||
import paths
|
||||
import sys
|
||||
import config
|
||||
|
||||
APP_LOG_FILE = 'debug.log'
|
||||
ERROR_LOG_FILE = "error.log"
|
||||
@ -24,8 +25,7 @@ server_log.setLevel(logging.WARNING)
|
||||
|
||||
|
||||
logger = logging.getLogger()
|
||||
logger.setLevel(logging.DEBUG)
|
||||
|
||||
logger.setLevel(logging.WARNING)
|
||||
#handlers
|
||||
|
||||
app_handler = RotatingFileHandler(paths.logs_path(APP_LOG_FILE), mode="w")
|
||||
|
@ -54,8 +54,10 @@ if system == "Linux":
|
||||
log = logging.getLogger("main")
|
||||
|
||||
def setup():
|
||||
log.debug("Starting " + application.name + " %s" % (application.version,))
|
||||
config.setup()
|
||||
if not config.app['app-settings']['paranoid']:
|
||||
logger.setLevel(logging.DEBUG)
|
||||
log.debug("Starting " + application.name + " %s" % (application.version,))
|
||||
log.debug("Using %s %s" % (platform.system(), platform.architecture()[0]))
|
||||
log.debug("Application path is %s" % (paths.app_path(),))
|
||||
log.debug("config path is %s" % (paths.config_path(),))
|
||||
|
Loading…
x
Reference in New Issue
Block a user