code: def test_imap_fail_on_non_iterable(pool):
      def fn(_):
          pass
  
      non_iterable = 3
  
      with pytest.raises(TypeError, match="object is not iterable"):
          pool.imap(fn, non_iterable)
  
      with pytest.raises(TypeError, match="object is not iterable"):
          pool.imap_unordered(fn, non_iterable)
  
imports: import os
  import sys
  import platform
  import pytest
  import tempfile
  import time
  import random
  from collections import defaultdict
  import queue
  import math
  import ray
  from ray._private.test_utils import SignalActor
  from ray.util.multiprocessing import Pool, TimeoutError, JoinableQueue
  from ray.util.joblib import register_ray
  from joblib import parallel_backend, Parallel, delayed
label_desc: Use image node_id 20 for calling a global function with example usage: test_imap_fail_on_non_iterable(pool) without return types