code: def do_enum_test(
      sdk_enum: Any,
      bindings_enum: Any,
      *,
      ignore: Optional[list] = None,
  ) -> None:
      # Every sdk enum member exists in bindings.
      extra_sdk_names = []
      for k, v in sdk_enum.__members__.items():
          if ignore and v in ignore:
              continue
          try:
              bindings_enum(v.value)
          except ValueError:
              extra_sdk_names.append(k)
  
      # Every bindings enum member exists in sdk.
      extra_bindings_names = []
      for k, v in bindings_enum.__members__.items():
          if ignore and v in ignore:
              continue
          try:
              sdk_enum(v.value)
          except ValueError:
              extra_bindings_names.append(k)
  
      errs = []
      if extra_sdk_names:
          errs.append(
              f"detected {extra_sdk_names} which are not valid bindings values\n"
          )
  
      if extra_bindings_names:
          errs.append(
              f"detected {extra_bindings_names} which are not valid sdk values\n"
          )
  
      assert not errs, " and ".join(errs)
  
file_path: determined/harness/tests/test_sdk.py
imports: from typing import Any, Optional
  from determined.common.api import bindings
  from determined.experimental import client
label_desc: Use image node_id 1 for calling a global function with example usage: do_enum_test(sdk_enum, bindings_enum) without return types