mirror of
https://github.com/ElementsProject/lightning.git
synced 2024-11-19 09:54:16 +01:00
pyln: Catch OSError when cleaning up test directories
This commit is contained in:
parent
fc071c6784
commit
a5f16ab5b1
@ -90,7 +90,7 @@ def directory(request, test_base_dir, test_name):
|
||||
if not failed:
|
||||
try:
|
||||
shutil.rmtree(directory)
|
||||
except Exception:
|
||||
except (OSError, Exception):
|
||||
files = [os.path.join(dp, f) for dp, dn, fn in os.walk(directory) for f in fn]
|
||||
print("Directory still contains files:", files)
|
||||
raise
|
||||
|
Loading…
Reference in New Issue
Block a user