Python模块化开发组织代码程序示例(5)

if __name__ == '__main__':
    while True:
        try:
            time.sleep(960)
            main_pool.poll()
        except KeyboardInterrupt:
            print("**** Interrupted!")
            break
        except threadpool.NoResultsPending:
            break

if main_pool.dismissedWorkers:
        print("Joining all dismissed worker threads...")
        main_pool.joinAllDismissedWorkers()

内容版权声明:除非注明,否则皆为本站原创文章。

转载注明出处:https://www.heiqu.com/4dfc40b6546e197aed6111875b47551c.html