From 69aae30416aae0f8f36ffbb7a11d22632440b288 Mon Sep 17 00:00:00 2001 From: dberenbaum Date: Wed, 18 Jan 2023 12:01:35 -0500 Subject: [PATCH] use os line separator --- src/dvclive/plots/metric.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/dvclive/plots/metric.py b/src/dvclive/plots/metric.py index c8a02a9c..719b5b2e 100644 --- a/src/dvclive/plots/metric.py +++ b/src/dvclive/plots/metric.py @@ -38,7 +38,7 @@ def dump(self, val, **kwargs) -> None: existed = self.output_path.exists() with open(self.output_path, "a", encoding="utf-8", newline="") as fobj: writer = csv.DictWriter( - fobj, row.keys(), delimiter="\t", lineterminator="\n" + fobj, row.keys(), delimiter="\t", lineterminator=os.linesep ) if not existed: writer.writeheader()