def METHOD_NAME(plugin_name: str, local_plugin_dir: str):
    module_name = plugin_name.replace("-", "_")
    module = _load_compat_x_prefix(plugin_name, module_name, local_plugin_dir)
    if module is None:
        sys.path = [local_plugin_dir] + sys.path
        logger.debug(
            f"Loading plugin module {module_name!r} with sys.path {sys.path!r}"
        )
        try:
            module = importlib.import_module(module_name)
        finally:
            sys.path.pop(0)
    return module