Tim Peters <t...@python.org> added the comment:
Antoine, alas, it's subtler than that. The worker process (process_func()) puts _another_ `StopIteration` on the input queue in its `finally` clause. So the first worker process to finish adds back a sentinel for the next worker to see, and so on. At the end, one StopIteration is left on input_queue (added by the last worker to finish). Everything shuts down cleanly for me on 64-bit Win10 Py 3.7.2 no matter what input I tried, so I can't reproduce. The OP really needs to identify _where_ it's hanging, and when (after all input has been read? somewhere "random in the middle"? ...), and if at all possible supply an input on which it does hang. The OP should also try 3.7.2. ---------- nosy: +tim.peters _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue35608> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com