code: def _get_signature(obj):
      if not inspect.isclass(obj) and not callable(obj):
          return None
  
      sig = ""
  
      # TODO: Can we replace below with this?
      # with contextlib.suppress(ValueError):
      #     sig = str(inspect.signature(obj))
  
      try:
          sig = str(inspect.signature(obj))
      except ValueError:
          sig = "(...)"
      except TypeError:
          return None
  
      is_delta_gen = False
      with contextlib.suppress(AttributeError):
          is_delta_gen = obj.__module__ == "streamlit.delta_generator"
          # Functions such as numpy.minimum don't have a __module__ attribute,
          # since we're only using it to check if its a DeltaGenerator, its ok
          # to continue
  
      if is_delta_gen:
          for prefix in CONFUSING_STREAMLIT_SIG_PREFIXES:
              if sig.startswith(prefix):
                  sig = sig.replace(prefix, "(")
                  break
  
      return sig
  
imports: import ast
  import contextlib
  import inspect
  import re
  import types
  from typing import TYPE_CHECKING, Any, cast
  from typing_extensions import Final
  import streamlit
  from streamlit.logger import get_logger
  from streamlit.proto.DocString_pb2 import DocString
  from streamlit.proto.DocString_pb2 import Member
  from streamlit.runtime.metrics_util import gather_metrics
  from streamlit.runtime.scriptrunner.script_runner import __file__
  from streamlit.runtime.secrets import Secrets
  from streamlit.string_util import is_mem_address_str
label_desc: Use image node_id 4 for calling a global function with example usage: _get_signature(obj) and returns: sig, None, None