[DEBUG/MainProcess] created semlock with handle 139661071269888 [DEBUG/MainProcess] created semlock with handle 139661071265792 [DEBUG/MainProcess] created semlock with handle 139661071261696 [DEBUG/MainProcess] created semlock with handle 139661071257600 [DEBUG/MainProcess] added worker [INFO/ForkPoolWorker-1] child process calling self.run() If no stdout message after this message we hung in apply_async Expected early termination of apply_async. Request output not available Worker process terminated OK without exceptions or timeout apply_async completed with valid result from worker process [DEBUG/MainProcess] terminating pool [DEBUG/MainProcess] finalizing pool [DEBUG/MainProcess] helping task handler/workers to finish [DEBUG/MainProcess] removing tasks from inqueue until task handler finished [DEBUG/MainProcess] worker handler exiting [DEBUG/MainProcess] task handler got sentinel [DEBUG/MainProcess] task handler sending sentinel to result handler [DEBUG/MainProcess] task handler sending sentinel to workers [DEBUG/MainProcess] result handler got sentinel [DEBUG/MainProcess] ensuring that outqueue is not full [DEBUG/ForkPoolWorker-1] worker got sentinel -- exiting [DEBUG/ForkPoolWorker-1] worker exiting after 1 tasks [INFO/ForkPoolWorker-1] process shutting down [DEBUG/MainProcess] result handler exiting: len(cache)=0, thread._state=0 [DEBUG/ForkPoolWorker-1] running all "atexit" finalizers with priority >= 0 [DEBUG/ForkPoolWorker-1] running the remaining "atexit" finalizers [INFO/ForkPoolWorker-1] process exiting with exitcode 0 [DEBUG/MainProcess] task handler exiting [DEBUG/MainProcess] joining worker handler [DEBUG/MainProcess] terminating workers [DEBUG/MainProcess] joining task handler [DEBUG/MainProcess] joining result handler [DEBUG/MainProcess] joining pool workers [DEBUG/MainProcess] cleaning up worker 4636 If no stdout message after this message we hung in main after standalone invocation of f() We are exiting without error or lock from main after standalone invocation of f() [INFO/MainProcess] process shutting down [DEBUG/MainProcess] running all "atexit" finalizers with priority >= 0 [DEBUG/MainProcess] running the remaining "atexit" finalizers