(path: Path)
| 436 | |
| 437 | |
| 438 | def 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 | |
| 450 | def clean_cache() -> None: |
no test coverage detected