MCPcopy Create free account
hub / github.com/IQEngine/IQEngine / get_core_plugin_definition

Function get_core_plugin_definition

plugins/src/plugins_api.py:78–88  ·  view source on GitHub ↗
(plugin_name: str)

Source from the content-addressed store, hash-verified

76
77
78async def get_core_plugin_definition(plugin_name: str):
79 try:
80 print("plugin_name:", plugin_name)
81 return getattr( __import__(plugin_name + "." + plugin_name, fromlist=["Plugin"]), "Plugin")
82 except AttributeError:
83 raise fastapi.HTTPException(status_code=404, detail="Plugin definition could not be generated")
84 except KeyError as err:
85 print(err)
86 raise fastapi.HTTPException(status_code=500, detail="Error in plugin definition")
87 except ModuleNotFoundError:
88 raise fastapi.HTTPException(status_code=404, detail="Plugin does not exist")

Callers 2

get_plugin_definitionFunction · 0.85
runFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected