mirror of
https://github.com/langbot-app/LangBot.git
synced 2026-06-10 07:46:02 +00:00
feat: 插件安装支持
This commit is contained in:
@@ -21,6 +21,7 @@ class PluginInstaller(metaclass=abc.ABCMeta):
|
||||
async def install_plugin(
|
||||
self,
|
||||
plugin_source: str,
|
||||
task_context: taskmgr.TaskContext = taskmgr.TaskContext.placeholder(),
|
||||
):
|
||||
"""安装插件
|
||||
"""
|
||||
|
||||
@@ -65,10 +65,11 @@ class PluginManager:
|
||||
async def install_plugin(
|
||||
self,
|
||||
plugin_source: str,
|
||||
task_context: taskmgr.TaskContext = taskmgr.TaskContext.placeholder(),
|
||||
):
|
||||
"""安装插件
|
||||
"""
|
||||
await self.installer.install_plugin(plugin_source)
|
||||
await self.installer.install_plugin(plugin_source, task_context)
|
||||
|
||||
await self.ap.ctr_mgr.plugin.post_install_record(
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user