2
0
mirror of https://github.com/frappe/bench.git synced 2024-11-12 00:06:36 +00:00

chore: remove unused class

This commit is contained in:
Gavin D'souza 2020-05-21 13:15:19 +05:30
parent 7dc5fdb7b3
commit 0ba5a09975

View File

@ -435,20 +435,12 @@ def setup_logging(bench_path='.'):
self._log(LOG_LEVEL, message, args, **kws)
logging.Logger.log = logv
class log_filter(object):
def __init__(self, level):
self.__level = level
def filter(self, logRecord):
return logRecord.levelno == self.__level
if os.path.exists(os.path.join(bench_path, 'logs')):
logger = logging.getLogger(bench.PROJECT_NAME)
log_file = os.path.join(bench_path, 'logs', 'bench.log')
formatter = logging.Formatter('%(asctime)s %(levelname)s %(message)s')
hdlr = logging.FileHandler(log_file)
hdlr.setFormatter(formatter)
logger.addHandler(hdlr)
logger.setLevel(logging.DEBUG)