Skip to content

Commit

Permalink
More inclusive timeout error checking to account for different errors…
Browse files Browse the repository at this point in the history
… during testing
  • Loading branch information
scnerd committed Nov 17, 2017
1 parent 42f62fb commit 382bc5f
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion miniutils/progress_bar.py
@@ -1,5 +1,6 @@
import itertools
import multiprocessing as mp
from nose.plugins.multiprocess import TimedOutException
import random
import warnings

Expand Down Expand Up @@ -105,7 +106,7 @@ def _parallel_progbar_launch(mapper, iterable, nprocs=None, starmap=False, flatm
for p in procs:
try:
p.join(1)
except TimeoutError:
except (TimeoutError, mp.TimeoutError, TimedOutException):
warnings.warn("parallel_progbar mapping process failed to close properly (check error output)")


Expand Down

0 comments on commit 382bc5f

Please sign in to comment.