code: def test_actor_failure_async(ray_start_regular):
      @ray.remote
      class A:
          def echo(self):
              pass
  
          def pid(self):
              return os.getpid()
  
      a = A.remote()
      rs = []
  
      def submit():
          for i in range(10000):
              r = a.echo.remote()
              r._on_completed(lambda x: 1)
              rs.append(r)
  
      t = threading.Thread(target=submit)
      pid = ray.get(a.pid.remote())
  
      t.start()
      from time import sleep
  
      sleep(0.1)
      os.kill(pid, SIGKILL)
  
      t.join()
  
imports: import os
  import sys
  import signal
  import threading
  import json
  from pathlib import Path
  import ray
  import numpy
  import pytest
  import psutil
  import time
  from ray._private.test_utils import SignalActor, wait_for_pid_to_exit, wait_for_condition, run_string_as_driver_nonblocking
label_desc: Use image node_id 4 for calling a global function with example usage: test_actor_failure_async(ray_start_regular) and returns: os