Skip to content

Commit

Permalink
Await cache cleaning
Browse files Browse the repository at this point in the history
Recursively removing the cache dir can actually take some time so we
risk concurrent access from our cleaning code and zig, which is bad. I
also suspect zig might hang because of this.
  • Loading branch information
Kristian Larsson committed Jan 27, 2025
1 parent 487baf2 commit 582adbd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cli/src/acton.act
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ def clean_zig_local_cache(cap: file.FileCap):
limit = 5 * gb
if total_size > limit:
print("Build cache (", total_size // (1024*1024), "MB) over %dGB, cleaning it up." % (int(limit // gb)))
fs.rmtree(cache_dir)
await async fs.rmtree(cache_dir)
total_size = 0
if total_size == 0:
print("INFO: Acton local cache is empty: rebuilding Acton base which will take some time...")
Expand Down

0 comments on commit 582adbd

Please sign in to comment.