Try to cleanup a folder if we can ensure it's deletable.
(path: Path, consider_lock_dead_if_created_before: float)
| 318 | |
| 319 | |
| 320 | def try_cleanup(path: Path, consider_lock_dead_if_created_before: float) -> None: |
| 321 | """Try to cleanup a folder if we can ensure it's deletable.""" |
| 322 | if ensure_deletable(path, consider_lock_dead_if_created_before): |
| 323 | maybe_delete_a_numbered_dir(path) |
| 324 | |
| 325 | |
| 326 | def cleanup_candidates(root: Path, prefix: str, keep: int) -> Iterator[Path]: |
no test coverage detected