code: def _import_mapping(mapping, original=None):
      """import any string-keys in a type mapping"""
      log = get_logger()
      log.debug("Importing canning map")
      for key, _ in list(mapping.items()):
          if isinstance(key, str):
              try:
                  cls = import_item(key)
              except Exception:
                  if original and key not in original:
                      # only message on user-added classes
                      log.error(
                          "canning class not importable: %r",
                          key,
                          exc_info=True,
                      )  # noqa: G201
                  mapping.pop(key)
              else:
                  mapping[cls] = mapping.pop(key)
  
imports: import typing
  import warnings
  import copy
  import pickle
  import sys
  from types import FunctionType
  from ipyparallel.serialize import codeutil
  from traitlets.log import get_logger
  from traitlets.utils.importstring import import_item
label_desc: Use image node_id 5 for calling a global function with example usage: _import_mapping(mapping, original) without return types