code: def test_lightweight_config_options(
      manage_ray_with_telemetry, lightweight_option, value
  ):
      """
      Check that lightweight config options are detected by telemetry.
      """
  
      lightweight_tagkeys = {
          "num_replicas": ServeUsageTag.NUM_REPLICAS_LIGHTWEIGHT_UPDATED,
          "user_config": ServeUsageTag.USER_CONFIG_LIGHTWEIGHT_UPDATED,
          "autoscaling_config": ServeUsageTag.AUTOSCALING_CONFIG_LIGHTWEIGHT_UPDATED,
      }
  
      subprocess.check_output(["ray", "start", "--head"])
      wait_for_condition(check_ray_started, timeout=5)
      storage = TelemetryStorage.remote()
  
      serve.run(
          receiver_app,
          host="0.0.0.0",
          name="telemetry",
          route_prefix=TELEMETRY_ROUTE_PREFIX,
      )
  
      wait_for_condition(
          lambda: ray.get(storage.get_reports_received.remote()) > 1,
          timeout=15,
      )
  
      # Check that REST API telemetry is not set
      report = ray.get(storage.get_report.remote())
      assert (
          ServeUsageTag.REST_API_VERSION.get_value_from_report(report)
          is None
      )
  
      serve.delete(name="telemetry", _blocking=True)
  
      config = {
          "applications": [
              {
                  "name": "receiver_app",
                  "import_path": "ray.serve._private.test_utils.receiver_app",
                  "route_prefix": TELEMETRY_ROUTE_PREFIX,
              },
              {
                  "name": "test_app",
                  "import_path": "ray.serve.tests.test_telemetry.tester",
                  "deployments": [{"name": "Tester"}],
              },
          ]
      }
  
      # Deploy first config
      serve.start()
      client = _get_global_client()
      client.deploy_apps(ServeDeploySchema(**config))
      wait_for_condition(
          lambda: serve.status().applications["receiver_app"].status
          == ApplicationStatus.RUNNING,
          timeout=15,
      )
      wait_for_condition(
          lambda: serve.status().applications["test_app"].status
          == ApplicationStatus.RUNNING,
          timeout=15,
      )
  
      current_num_reports = ray.get(
          storage.get_reports_received.remote()
      )
  
      wait_for_condition(
          lambda: ray.get(storage.get_reports_received.remote())
          > current_num_reports,
          timeout=10,
      )
      report = ray.get(storage.get_report.remote())
  
      # Check
      assert (
          int(ServeUsageTag.NUM_APPS.get_value_from_report(report)) == 2
      )
      assert (
          ServeUsageTag.API_VERSION.get_value_from_report(report)
          == "v2"
      )
      for tagkey in lightweight_tagkeys.values():
          assert tagkey.get_value_from_report(report) is None
  
      # Change config and deploy again
      config["applications"][1]["deployments"][0][
          lightweight_option
      ] = value
      client.deploy_apps(ServeDeploySchema(**config))
      wait_for_condition(
          lambda: serve.status().applications["receiver_app"].status
          == ApplicationStatus.RUNNING,
          timeout=15,
      )
      wait_for_condition(
          lambda: serve.status().applications["test_app"].status
          == ApplicationStatus.RUNNING,
          timeout=15,
      )
  
      # Check again
      wait_for_condition(
          lambda: lightweight_tagkeys[
              lightweight_option
          ].get_value_from_report(ray.get(storage.get_report.remote()))
          == "True",
          timeout=5,
      )
      report = ray.get(storage.get_report.remote())
      assert (
          int(ServeUsageTag.NUM_APPS.get_value_from_report(report)) == 2
      )
      assert (
          ServeUsageTag.API_VERSION.get_value_from_report(report)
          == "v2"
      )
      for tagkey in lightweight_tagkeys.values():
          if tagkey != lightweight_tagkeys[lightweight_option]:
              assert tagkey.get_value_from_report(report) is None
  
imports: import subprocess
  import sys
  import time
  import pytest
  import requests
  import yaml
  from fastapi import FastAPI
  import ray
  from ray import serve
  from ray._private.test_utils import wait_for_condition
  from ray._private.usage.usage_lib import get_extra_usage_tags_to_report
  from ray.serve._private.common import ApplicationStatus
  from ray.serve._private.constants import SERVE_MULTIPLEXED_MODEL_ID
  from ray.serve._private.test_utils import TELEMETRY_ROUTE_PREFIX, TelemetryStorage, check_ray_started, receiver_app, start_telemetry_app
  from ray.serve._private.usage import ServeUsageTag
  from ray.serve.context import _get_global_client
  from ray.serve.schema import ServeDeploySchema
label_desc: Use image node_id 3 for calling a global function with example usage: test_lightweight_config_options(manage_ray_with_telemetry, lightweight_option, value) without return types