code: def test_max_call_tasks(ray_start_regular):
      @ray.remote(max_calls=1)
      def f():
          return os.getpid()
  
      pid = ray.get(f.remote())
      wait_for_pid_to_exit(pid)
  
      @ray.remote(max_calls=2)
      def f():
          return os.getpid()
  
      pid1 = ray.get(f.remote())
      pid2 = ray.get(f.remote())
      assert pid1 == pid2
      wait_for_pid_to_exit(pid1)
  
file_path: ray/python/ray/tests/test_advanced_6.py
imports: import logging
  import os
  import platform
  import signal
  import sys
  import time
  import psutil
  import pytest
  import ray
  import ray.cluster_utils
  from ray._private.test_utils import run_string_as_driver_nonblocking, wait_for_condition, wait_for_pid_to_exit
label_desc: Use image node_id 5 for calling a global function with example usage: test_max_call_tasks(ray_start_regular) and returns: os, os