Skip to content

Commit c14bf3a

Browse files
author
donghu-jiang
committed
保存日志指定参数名称
Change-Id: Ia494ee39a7a120c9610eb7d88ca96797a0ff1628
1 parent 18b1603 commit c14bf3a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

hub/log/log.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ def set_level(self, level):
3737
self.__logger.setLevel(level)
3838

3939
def create_file(self, file_path, max_bytes, backup_count):
40-
log_handler = RotatingFileHandler(file_path, max_bytes, backup_count)
40+
log_handler = RotatingFileHandler(filename=file_path, maxBytes=max_bytes, backupCount=backup_count)
4141
log_handler.setFormatter(logging.Formatter(self.__format))
4242
self.__logger.addHandler(log_handler)
4343

0 commit comments

Comments
 (0)