I am writing a Python program using its multiprocessing module. The program calls a number of worker functions, each yielding a random number. I need to terminate th
There is a much cleaner and pythonic way to do what you want to do and it's achieved by using the callback functions offered by multiprocessing.Pool.
multiprocessing.Pool
You can check this question to see an implementation example.