MCPcopy
hub / github.com/nonebot/nonebot2 / _revert_plugin

Function _revert_plugin

nonebot/plugin/__init__.py:127–132  ·  view source on GitHub ↗
(plugin: "Plugin")

Source from the content-addressed store, hash-verified

125
126
127def _revert_plugin(plugin: "Plugin") -> None:
128 if plugin.id_ not in _plugins:
129 raise RuntimeError("Plugin not found!")
130 del _plugins[plugin.id_]
131 if parent_plugin := plugin.parent_plugin:
132 parent_plugin.sub_plugins.discard(plugin)
133
134
135def get_plugin(plugin_id: str) -> "Plugin | None":

Callers 1

exec_moduleMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected