INNER CODE UNIT · Python

module_name

loxy0devlp/RedTiger-Tools · redtiger.py:44

            module_name = file[:-3]

            try:
                spec   = importlib.util.spec_from_file_location(module_name, path)
                module = importlib.util.module_from_spec(spec)
                spec.loader.exec_module(module)

                if hasattr(module, "Register"):
                    plugin_data = module.Register()
                    plugins[module_name] = plugin_data
            except Exception: continue

    if not plugins: return options_list
    existing_ids = set(options_list.keys())
    next_id      = max(existing_ids) + 1 if existing_ids else 1

    for plugin in plugins.values():
        name        = plugin.get("name", "Unknown")

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…