8000 TST: test_fork: Missing join · matplotlib/matplotlib@f1308bc · GitHub
[go: up one dir, main page]

Skip to content

Commit f1308bc

Browse files
committed
TST: test_fork: Missing join
Probably this is a cause of `test_fork` taking forever to complete sometimes.
1 parent eb18cb2 commit f1308bc

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

lib/matplotlib/tests/test_font_manager.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -197,4 +197,5 @@ def _model_handler(_):
197197
def test_fork():
198198
_model_handler(0) # Make sure the font cache is filled.
199199
ctx = multiprocessing.get_context("fork")
200-
ctx.Pool(processes=2).map(_model_handler, range(2))
200+
with ctx.Pool(processes=2) as pool:
201+
pool.map(_model_handler, range(2))

0 commit comments

Comments
 (0)
0