X-Git-Url: https://glassweightruler.freedombox.rocks/gitweb/waydroid.git/blobdiff_plain/2e4e921317903f5152ce17bc7aa9fdf278b45f15..HEAD:/tools/helpers/logging.py?ds=inline diff --git a/tools/helpers/logging.py b/tools/helpers/logging.py index 4b33735..9f3af64 100644 --- a/tools/helpers/logging.py +++ b/tools/helpers/logging.py @@ -71,9 +71,9 @@ def init(args): # Add file log handler if args.action == "container" and not args.details_to_stdout: os.chmod(args.log, 0o644) - handler = RotatingFileHandler(args.log, maxBytes=5*1024*1024) + handler = RotatingFileHandler(args.log, maxBytes=5*1024*1024, backupCount=1) handler.setFormatter(logging.Formatter("(%(process)d) [%(asctime)s] %(message)s", - datefmt="%H:%M:%S")) + datefmt="%a, %d %b %Y %H:%M:%S")) root_logger.addHandler(handler) def disable():