Merge pull request #6944 from piotrhm/issue_1120
This commit is contained in:
commit
3de85a9ac9
1
AUTHORS
1
AUTHORS
|
@ -227,6 +227,7 @@ Pedro Algarvio
|
||||||
Philipp Loose
|
Philipp Loose
|
||||||
Pieter Mulder
|
Pieter Mulder
|
||||||
Piotr Banaszkiewicz
|
Piotr Banaszkiewicz
|
||||||
|
Piotr Helm
|
||||||
Prashant Anand
|
Prashant Anand
|
||||||
Pulkit Goyal
|
Pulkit Goyal
|
||||||
Punyashloka Biswal
|
Punyashloka Biswal
|
||||||
|
|
|
@ -0,0 +1 @@
|
||||||
|
Fix issue where directories from tmpdir are not removed properly when multiple instances of pytest are running in parallel.
|
|
@ -338,11 +338,13 @@ def make_numbered_dir_with_cleanup(
|
||||||
e = exc
|
e = exc
|
||||||
else:
|
else:
|
||||||
consider_lock_dead_if_created_before = p.stat().st_mtime - lock_timeout
|
consider_lock_dead_if_created_before = p.stat().st_mtime - lock_timeout
|
||||||
cleanup_numbered_dir(
|
# Register a cleanup for program exit
|
||||||
root=root,
|
atexit.register(
|
||||||
prefix=prefix,
|
cleanup_numbered_dir,
|
||||||
keep=keep,
|
root,
|
||||||
consider_lock_dead_if_created_before=consider_lock_dead_if_created_before,
|
prefix,
|
||||||
|
keep,
|
||||||
|
consider_lock_dead_if_created_before,
|
||||||
)
|
)
|
||||||
return p
|
return p
|
||||||
assert e is not None
|
assert e is not None
|
||||||
|
|
Loading…
Reference in New Issue