docstr: Tests that when all worker processes have exited, zmq will properly throw an exception
  when trying to ventilate instead of blocking indefinitely
docstr_tok: ["Tests","that","when","all","worker","processes","have","exited",",","zmq","will","properly","throw","an","exception","when","trying","to","ventilate","instead","of","blocking","indefinitely"]
code: def test_exception_in_all_worker_process(self):
      """Tests that when all worker processes have exited, zmq will properly throw an exception
      when trying to ventilate instead of blocking indefinitely"""
      pool = ProcessPool(5)
      pool.start(ExceptionGeneratingWorker_5)
      with self.assertRaises(RuntimeError):
          for _ in range(10000):
              pool.ventilate("Datanum")
              time.sleep(0.1)
  
imports: import time
  import unittest
  import numpy
  from multiprocessing import Process, Manager
  from psutil import pid_exists
  from petastorm.workers_pool import EmptyResultError
  from petastorm.workers_pool.dummy_pool import DummyPool
  from petastorm.workers_pool.process_pool import ProcessPool
  from petastorm.workers_pool.tests.stub_workers import CoeffMultiplierWorker, WorkerIdGeneratingWorker, WorkerMultiIdGeneratingWorker, SleepyWorkerIdGeneratingWorker, ExceptionGeneratingWorker_5, PreprogrammedReturnValueWorker
  from petastorm.workers_pool.thread_pool import ThreadPool
label_desc: Use image node_id 19 for calling the TestWorkersPool obj's underlying member method code with example usage: obj.test_exception_in_all_worker_process() without return types