MCPcopy
hub / github.com/MaaEnd/MaaEnd / cleanup_cache_file

Function cleanup_cache_file

tools/setup_workspace.py:438–447  ·  view source on GitHub ↗
(path: Path)

Source from the content-addressed store, hash-verified

436
437
438def cleanup_cache_file(path: Path) -> None:
439 try:
440 if path.exists():
441 path.unlink()
442 print(Console.ok(t("inf_cache_cleaned", path=path)))
443 meta = Path(str(path) + ".url")
444 if meta.exists():
445 meta.unlink()
446 except OSError as e:
447 print(Console.warn(t("wrn_cache_clean_failed", path=path, error=e)))
448
449
450def clean_cache() -> None:

Callers 4

download_fileFunction · 0.85
install_maafwFunction · 0.85
install_mxuFunction · 0.85
install_cpp_algoFunction · 0.85

Calls 3

okMethod · 0.80
warnMethod · 0.80
tFunction · 0.70

Tested by

no test coverage detected