code: def _make_exception(msg, error_code):
      """Makes an exception with MLMD error code.
  
      Args:
        msg: Error message.
        error_code: MLMD error code.
  
      Returns:
        An exception.
      """
  
      try:
          exc_type = errors.exception_type_from_error_code(error_code)
          return exc_type(msg)
      except KeyError:
          return errors.UnknownError(msg)
  
imports: import abc
  from typing import Union
  from ml_metadata import errors
  from ml_metadata.metadata_store.pywrap.metadata_store_extension import metadata_store
  from ml_metadata.proto import metadata_store_pb2
  from ml_metadata.simple_types.proto import simple_types_pb2
label_desc: Use image node_id 1 for calling a global function with example usage: _make_exception(msg, error_code) and returns: exc_type, errors