mirror of
https://github.com/ROCm/jax.git
synced 2025-04-19 05:16:06 +00:00
Merge pull request #16390 from cloudhan:win-fix-cache-threading
PiperOrigin-RevId: 540123680
This commit is contained in:
commit
4d512c95e2
@ -48,8 +48,8 @@ class GFileCache(CacheInterface):
|
||||
f.write(value)
|
||||
f.flush()
|
||||
os.fsync(f.fileno())
|
||||
os.rename(tmp_path, path_to_new_file)
|
||||
os.replace(tmp_path, path_to_new_file)
|
||||
else:
|
||||
tmp_path = self._path / f"_temp_{key}"
|
||||
tmp_path.write_bytes(value)
|
||||
tmp_path.rename(str(path_to_new_file))
|
||||
tmp_path.replace(str(path_to_new_file))
|
||||
|
Loading…
x
Reference in New Issue
Block a user