Skip to content

Commit 598db74

Browse files
committed
Fix setting timestamp of local copies of files
1 parent c0c1531 commit 598db74

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

src/megatron/energon/local_copy.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,7 @@ def ensure_local_copy(path: EPath) -> EPath:
4747
# We are the downloader
4848
try:
4949
path.copy(EPath(tmp_path))
50+
os.utime(tmp_path, (tmp_path.stat().st_atime, mod_time))
5051
tmp_path.rename(final_path)
5152
finally:
5253
tmp_path.unlink(missing_ok=True)

0 commit comments

Comments
 (0)