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:
parent
7dc5fdb7b3
commit
0ba5a09975
@ -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)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user