code: def get_bundle(
      bundle_name: str,
      locale: str | Sequence[str | str] = None,
      path: Path | str = None,
  ) -> ResourceBundle:
      """
      Return a new :class:`ResourceBundle` after parsing the locale
  
      :param str bundle_name: The base name of the ResourceBundle
      :param str | Sequence[str | str] locale: The locale as a string or from the locale module
      :param Path | str | None path: The path to the ResourceBundle .properties files (default: current working directory)
      """
      # locale was not supplied
      if locale is None:
          return ResourceBundle(
              bundle_name=bundle_name, bundle_locale=None, path=path
          )
  
      # simple string
      if isinstance(locale, str):
          return ResourceBundle(
              bundle_name=bundle_name, bundle_locale=locale, path=path
          )
  
      # locale from the locale module
      extracted_locale, _ = locale
      return ResourceBundle(
          bundle_name=bundle_name,
          bundle_locale=extracted_locale,
          path=path,
      )
  
imports: from __future__ import annotations
  import codecs
  import os
  import re
  from os import PathLike
  from pathlib import Path
  from typing import KeysView, Sequence
  from .exceptions import MalformedResourceBundleError, NotInResourceBundleError
label_desc: Use image node_id 1 for calling a global function with example usage: get_bundle(bundle_name, locale, path) and returns: ResourceBundle, ResourceBundle, ResourceBundle