def write_block_record(self, *args, **kwargs):
if self.block_coordinator is not None:
if self.block_coordinator.should_log():
record = BlockRecord(*args, **kwargs)
filename = self.block_coordinator.get_filename()
with open(filename, "wb") as f:
pickler = pickle.Pickler(f)
pickler.dump(record)
self.block_coordinator.step()
评论列表
文章目录