Loading csst_common/pipeline.py +13 −0 Original line number Diff line number Diff line Loading @@ -54,6 +54,7 @@ class Pipeline: self.message = Message(os.path.join(self.dir_out, "msg.txt")) self.time_stamp = TimeStamp(os.path.join(self.dir_out, "time_stamp.txt")) self.exit_code = ExitCode(os.path.join(self.dir_out, "exit_code")) self.error_trace = ErrorTrace(os.path.join(self.dir_out, "error_trace")) if dfs: self.dfs = DFS(n_try=5) Loading Loading @@ -101,6 +102,18 @@ class Pipeline: warnings.resetwarnings() class ErrorTrace: def __init__(self, file_path=""): self.file_path = file_path def __repr__(self): return f"< ErrorTrace [{self.file_path}] >" def write(self, s: str): with open(self.file_path, "w+") as f: f.write(s) class Message: def __init__(self, file_path=""): self.file_path = file_path Loading Loading
csst_common/pipeline.py +13 −0 Original line number Diff line number Diff line Loading @@ -54,6 +54,7 @@ class Pipeline: self.message = Message(os.path.join(self.dir_out, "msg.txt")) self.time_stamp = TimeStamp(os.path.join(self.dir_out, "time_stamp.txt")) self.exit_code = ExitCode(os.path.join(self.dir_out, "exit_code")) self.error_trace = ErrorTrace(os.path.join(self.dir_out, "error_trace")) if dfs: self.dfs = DFS(n_try=5) Loading Loading @@ -101,6 +102,18 @@ class Pipeline: warnings.resetwarnings() class ErrorTrace: def __init__(self, file_path=""): self.file_path = file_path def __repr__(self): return f"< ErrorTrace [{self.file_path}] >" def write(self, s: str): with open(self.file_path, "w+") as f: f.write(s) class Message: def __init__(self, file_path=""): self.file_path = file_path Loading