code: def _warning_with_component(component, msg):
      if component._logger is None:
          return None
      if component._warned_once:
          return None
      log_msg = "[@card-component WARNING] %s" % msg
      component._logger(log_msg, timestamp=False, bad=True)
      component._warned_once = True
  
imports: from typing import Any, List, Optional, Union
  from .basic import LogComponent, ErrorComponent, ArtifactsComponent, TableComponent, ImageComponent, SectionComponent, MarkdownComponent
  from .card import MetaflowCardComponent
  from .convert_to_native_type import TaskToDict, _full_classname
  from .renderer_tools import render_safely
  import uuid
label_desc: Use image node_id 3 for calling a global function with example usage: _warning_with_component(component, msg) and returns: None, None