ThreadPool.py: Added healthy threadpool termination