Closed MirrorCY closed 2 years ago
哈喽Anillc,上午好!
首先感谢你制作了这个适配器~为了一群使用NovelAI-bot的可爱群友们不受炸群和封号的困扰,我发现这个适配器后立马搭建了一个Synapse服务器,但是试图在koishi中安装适配器插件时遇到了麻烦。
我尝试了使用插件市场安装以及npm安装,并使用npm install koa安装了依赖,但都没能正常运行,日志报错为[W] market failed to parse koishi-plugin-adapter-matrix
[W] market failed to parse koishi-plugin-adapter-matrix
安装环境测试了windows下koishi-desktop,windows docker desktop,以及Ubuntu22.04下的docker。分别尝试了koishi 4.9.7到4.9.5,均没能让koishi识别出这个适配器。
我也尝试使用npm install koishi-plugin-adapter-matrix 并在koishi.yml中配置参数,也没能奏效,日志中报错如下。
npm install koishi-plugin-adapter-matrix
查看了koishi开发文档并对照了其他bot的源码后我完全没有头绪,这似乎不是一个小白可以搞定的东西🤣
如果是因为koishi更新导致的不兼容,有没有较为简单的方法可以修复这个问题呢?如果有需要的话,我可以提供力所能及的一切帮助,期待并感谢你的回复~
附:报错日志
npm run start Debugger attached.
@koishijs/boilerplate@1.1.9 start koishi start -r yml-register
Debugger attached. Debugger attached. 2022-10-29 10:03:45 [I] app Koishi/4.9.7 2022-10-29 10:03:45 [I] app apply plugin group:entry 2022-10-29 10:03:45 [I] app apply plugin group:basic 2022-10-29 10:03:45 [I] app apply plugin help 2022-10-29 10:03:45 [I] app apply plugin rate-limit 2022-10-29 10:03:45 [I] app apply plugin suggest 2022-10-29 10:03:45 [I] app apply plugin locales 2022-10-29 10:03:45 [I] app apply plugin commands 2022-10-29 10:03:45 [I] app apply plugin group:console 2022-10-29 10:03:45 [I] app apply plugin console 2022-10-29 10:03:45 [I] app apply plugin dataview 2022-10-29 10:03:45 [I] app apply plugin logger 2022-10-29 10:03:45 [I] app apply plugin insight 2022-10-29 10:03:45 [I] app apply plugin market 2022-10-29 10:03:45 [I] app apply plugin sandbox 2022-10-29 10:03:45 [I] app apply plugin status 2022-10-29 10:03:45 [I] app apply plugin group:database 2022-10-29 10:03:45 [I] app apply plugin database-memory 2022-10-29 10:03:45 [I] app apply plugin group:adapter 2022-10-29 10:03:45 [I] app apply plugin adapter-discord 2022-10-29 10:03:45 [I] app apply plugin gocqhttp 2022-10-29 10:03:45 [I] app apply plugin koishi-plugin-adapter-matrix 2022-10-29 10:03:45 [W] app TypeError: koishi_1.Adapter.define is not a function at Object. (C:\Users\5800h\AppData\Roaming\Il Harper\Koishi\data\instances\default\node_modules\koishi-plugin-adapter-matrix\lib\index.js:6:36) at Module._compile (node:internal/modules/cjs/loader:1159:14) at Module._extensions..js (node:internal/modules/cjs/loader:1213:10) at Module.load (node:internal/modules/cjs/loader:1037:32) at Module._load (node:internal/modules/cjs/loader:878:12) at Module.require (node:internal/modules/cjs/loader:1061:19) at require (node:internal/modules/cjs/helpers:103:18) at NodeLoader.resolvePlugin (C:\Users\5800h\AppData\Roaming\Il Harper\Koishi\data\instances\default\node_modules\@koishijs\loader\lib\node.js:136:45) at NodeLoader.forkPlugin (C:\Users\5800h\AppData\Roaming\Il Harper\Koishi\data\instances\default\node_modules\@koishijs\loader\lib\shared.js:194:31) at NodeLoader.reloadPlugin (C:\Users\5800h\AppData\Roaming\Il Harper\Koishi\data\instances\default\node_modules\@koishijs\loader\lib\shared.js:217:27) 2022-10-29 10:03:45 [I] app server listening at http://localhost:5140 2022-10-29 10:03:45 [W] market failed to parse koishi-plugin-adapter-matrix
已在新版本中解决。
哈喽Anillc,上午好!
首先感谢你制作了这个适配器~为了一群使用NovelAI-bot的可爱群友们不受炸群和封号的困扰,我发现这个适配器后立马搭建了一个Synapse服务器,但是试图在koishi中安装适配器插件时遇到了麻烦。
我尝试了使用插件市场安装以及npm安装,并使用npm install koa安装了依赖,但都没能正常运行,日志报错为
[W] market failed to parse koishi-plugin-adapter-matrix
安装环境测试了windows下koishi-desktop,windows docker desktop,以及Ubuntu22.04下的docker。分别尝试了koishi 4.9.7到4.9.5,均没能让koishi识别出这个适配器。
我也尝试使用
npm install koishi-plugin-adapter-matrix
并在koishi.yml中配置参数,也没能奏效,日志中报错如下。查看了koishi开发文档并对照了其他bot的源码后我完全没有头绪,这似乎不是一个小白可以搞定的东西🤣
如果是因为koishi更新导致的不兼容,有没有较为简单的方法可以修复这个问题呢?如果有需要的话,我可以提供力所能及的一切帮助,期待并感谢你的回复~
附:报错日志
npm run start Debugger attached.
Debugger attached. Debugger attached. 2022-10-29 10:03:45 [I] app Koishi/4.9.7 2022-10-29 10:03:45 [I] app apply plugin group:entry 2022-10-29 10:03:45 [I] app apply plugin group:basic 2022-10-29 10:03:45 [I] app apply plugin help 2022-10-29 10:03:45 [I] app apply plugin rate-limit 2022-10-29 10:03:45 [I] app apply plugin suggest 2022-10-29 10:03:45 [I] app apply plugin locales 2022-10-29 10:03:45 [I] app apply plugin commands 2022-10-29 10:03:45 [I] app apply plugin group:console 2022-10-29 10:03:45 [I] app apply plugin console 2022-10-29 10:03:45 [I] app apply plugin dataview 2022-10-29 10:03:45 [I] app apply plugin logger 2022-10-29 10:03:45 [I] app apply plugin insight 2022-10-29 10:03:45 [I] app apply plugin market 2022-10-29 10:03:45 [I] app apply plugin sandbox 2022-10-29 10:03:45 [I] app apply plugin status 2022-10-29 10:03:45 [I] app apply plugin group:database 2022-10-29 10:03:45 [I] app apply plugin database-memory 2022-10-29 10:03:45 [I] app apply plugin group:adapter 2022-10-29 10:03:45 [I] app apply plugin adapter-discord 2022-10-29 10:03:45 [I] app apply plugin gocqhttp 2022-10-29 10:03:45 [I] app apply plugin koishi-plugin-adapter-matrix 2022-10-29 10:03:45 [W] app TypeError: koishi_1.Adapter.define is not a function at Object. (C:\Users\5800h\AppData\Roaming\Il Harper\Koishi\data\instances\default\node_modules\koishi-plugin-adapter-matrix\lib\index.js:6:36)
at Module._compile (node:internal/modules/cjs/loader:1159:14)
at Module._extensions..js (node:internal/modules/cjs/loader:1213:10)
at Module.load (node:internal/modules/cjs/loader:1037:32)
at Module._load (node:internal/modules/cjs/loader:878:12)
at Module.require (node:internal/modules/cjs/loader:1061:19)
at require (node:internal/modules/cjs/helpers:103:18)
at NodeLoader.resolvePlugin (C:\Users\5800h\AppData\Roaming\Il Harper\Koishi\data\instances\default\node_modules\@koishijs\loader\lib\node.js:136:45)
at NodeLoader.forkPlugin (C:\Users\5800h\AppData\Roaming\Il Harper\Koishi\data\instances\default\node_modules\@koishijs\loader\lib\shared.js:194:31)
at NodeLoader.reloadPlugin (C:\Users\5800h\AppData\Roaming\Il Harper\Koishi\data\instances\default\node_modules\@koishijs\loader\lib\shared.js:217:27)
2022-10-29 10:03:45 [I] app server listening at http://localhost:5140
2022-10-29 10:03:45 [W] market failed to parse koishi-plugin-adapter-matrix