[Koishi Desktop] market的插件不能用了

在我更新了koishi后,market插件突然不能用了,插件市场打开是这样的


依赖管理是这样的

日志输出了这些

2024-02-17 21:47:44 [I] loader unload plugin market:7o3j74
2024-02-17 21:47:45 [I] loader apply plugin market:7o3j74
2024-02-17 21:47:45 [W] market ReferenceError: Headers is not defined
                            at Proxy.[cordis.invoke] (/home/jingming295/.koishi/data/instances/default/node_modules/undios/lib/index.cjs:153:23)
                            at Function.applyProxy (/home/jingming295/.koishi/data/instances/default/node_modules/@cordisjs/core/lib/index.cjs:722:35)
                            at http (/home/jingming295/.koishi/data/instances/default/node_modules/@cordisjs/core/lib/index.cjs:977:24)
                            at Proxy.<anonymous> (/home/jingming295/.koishi/data/instances/default/node_modules/undios/lib/index.cjs:70:36)
                            at _MarketProvider.collect (/home/jingming295/.koishi/data/instances/default/node_modules/@koishijs/plugin-market/lib/node/index.js:391:38)
                            at _MarketProvider.prepare (/home/jingming295/.koishi/data/instances/default/node_modules/@koishijs/plugin-market/lib/shared/index.js:52:45)
                            at _MarketProvider.start (/home/jingming295/.koishi/data/instances/default/node_modules/@koishijs/plugin-market/lib/node/index.js:382:16)
                            at /home/jingming295/.koishi/data/instances/default/node_modules/@cordisjs/core/lib/index.cjs:994:18
                            at processTicksAndRejections (node:internal/process/task_queues:96:5)
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market ReferenceError: Headers is not defined
                            at Proxy.[cordis.invoke] (/home/jingming295/.koishi/data/instances/default/node_modules/undios/lib/index.cjs:153:23)
                            at Function.applyProxy (/home/jingming295/.koishi/data/instances/default/node_modules/@cordisjs/core/lib/index.cjs:722:35)
                            at http (/home/jingming295/.koishi/data/instances/default/node_modules/@cordisjs/core/lib/index.cjs:977:24)
                            at Proxy.<anonymous> (/home/jingming295/.koishi/data/instances/default/node_modules/undios/lib/index.cjs:70:36)
                            at _MarketProvider.collect (/home/jingming295/.koishi/data/instances/default/node_modules/@koishijs/plugin-market/lib/node/index.js:391:38)
                            at _MarketProvider.prepare (/home/jingming295/.koishi/data/instances/default/node_modules/@koishijs/plugin-market/lib/shared/index.js:52:45)
                            at _MarketProvider.get (/home/jingming295/.koishi/data/instances/default/node_modules/@koishijs/plugin-market/lib/node/index.js:425:16)
                            at /home/jingming295/.koishi/data/instances/default/node_modules/@koishijs/console/lib/index.js:57:25
                            at /home/jingming295/.koishi/data/instances/default/node_modules/@koishijs/console/lib/index.js:247:27
                            at processTicksAndRejections (node:internal/process/task_queues:96:5)
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined
2024-02-17 21:47:45 [W] market Headers is not defined

把 registry.endpoint改成https://registry.npmjs.org/
search.endpoint改成https://registry.koishi.chat/index.json
也没用

这是我的market插件配置

koishi版本为:

Core: 4.17.0-beta.2

Console: 5.27.9

Koishi Desktop: 0.10.7

market 版本为: 2.11.1

2 个赞

全部依赖升级至最新版本即可解决

1 个赞

如果我的market不能用的话我应该怎么升级,直接到.koishi 里面执行 yarn upgrade吗?

我koishi 每次都是用koishi的appimage启动的,每次执行完yarn upgrade以后就打不开了,需要 koi.AppImage yarn -n default 才能再次成功打开,然后打开后还是一样的情况,market没法用

2 个赞

(试试yarn dep?

3 个赞

我看见里面的package.json只有一个 start script


我添加了dep的script

然后我运行yarn dep

输出

jingming295@jingming295-PowerEdge-R730:~/.koishi/data/instances/default$ yarn dep           yarn run v1.22.19
$ yakumo upgrade
/bin/sh: line 1: yakumo: command not found
error Command failed with exit code 127.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
jingming295@jingming295-PowerEdge-R730:~/.koishi/data/instances/default$

貌似原本就没有 yakumo (我这个koishi是用appimage启动的)

2 个赞

soga))那没事了)

2 个赞

然而我在.koishi/data/instances/default 运行 yarn start的时候启动成功了

并且插件市场也是好的

使用 koi start default 就永远无法启动起来,是否意味着我以后只能进入.koishi/data/instances/default 运行 yarn start 来启动koishi了

1 个赞

我不确定这是不是koishi desktop 的问题,所以我发了一个issue: Issues · koishijs/koishi-desktop · GitHub

1 个赞
1 个赞