def _append_to_temp_manifest(database, cluster, schema, table, tmp_manifest_path=paths.TMP_MANIFEST_PATH): relative_file_path = get_table_file_path_relative(database, cluster, schema, table) with open(tmp_manifest_path, "a") as f: f.write(relative_file_path + "\n")
def record(self): relative_file_path = get_table_file_path_relative( self.database, self.cluster, self.schema, self.table) + f"/{self.name}.csv" record_path = os.path.join(paths.METRICS_PATH, relative_file_path) record_dirname = os.path.dirname(record_path) Path(record_dirname).mkdir(parents=True, exist_ok=True) with open(record_path, "a") as f: f.write(f"{self.value},{self.execution_time}\n")