摘要: Python通过重写sys.stdout将控制台日志重定向到文件 class Logger(object): def __init__(self,fileN ="Default.log"): self.terminal = sys.stdout self.log = open(fileN,"a") 阅读全文
posted @ 2021-10-29 16:41 左岸丶 阅读(595) 评论(0) 推荐(0) 编辑