(_: EmptyPayload)
| 874 | } |
| 875 | |
| 876 | async reloadPlugins(_: EmptyPayload): Promise<ReloadPluginsResult> { |
| 877 | try { |
| 878 | const summary = await this.plugins.reload(); |
| 879 | this.pluginsLoadError = undefined; |
| 880 | return summary; |
| 881 | } catch (error) { |
| 882 | this.pluginsLoadError = error instanceof Error ? error : new Error(String(error)); |
| 883 | throw new KimiError( |
| 884 | ErrorCodes.PLUGIN_LOAD_FAILED, |
| 885 | `Failed to reload plugins: ${this.pluginsLoadError.message}`, |
| 886 | { cause: error, details: { kimiHomeDir: this.homeDir } }, |
| 887 | ); |
| 888 | } |
| 889 | } |
| 890 | |
| 891 | async getPluginInfo({ id }: GetPluginInfoPayload): Promise<PluginInfo> { |
| 892 | await this.pluginsReady; |
no test coverage detected