swh.loader.core.utils module

swh.loader.core.utils.clean_dangling_folders(dirpath, pattern_check, log=None)[source]
Clean up potential dangling temporary working folder rooted at

dirpath. Those folders must match a dedicated pattern and not belonging to a live pid.

  • dirpath (str) – Path to check for dangling files

  • pattern_check (str) – A dedicated pattern to check on first

  • directory (e.g swh.loader.mercurial. (level) –

:param : :param swh.loader.svn.): :param log: Optional logger :type log: Logger