From 8a811688900cb477c4a2bbb5203db9799166189a Mon Sep 17 00:00:00 2001 From: Faiz Surani Date: Fri, 6 Dec 2024 14:50:26 -0800 Subject: [PATCH] Fix rl touch --- rl/cli/main.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/rl/cli/main.py b/rl/cli/main.py index 203b190..48b097c 100644 --- a/rl/cli/main.py +++ b/rl/cli/main.py @@ -482,8 +482,7 @@ def _get_all_jobs(partition: str | None = None, show_progress=False): def _touch_file(path: Path): - with path.open("ab") as f: - f.write(b" ") + subprocess.run(["truncate", "-s", "+1", str(path)]) subprocess.run(["truncate", "-s", "-1", str(path)])