惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

月光博客
月光博客
Stack Overflow Blog
Stack Overflow Blog
L
LangChain Blog
Jina AI
Jina AI
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
雷峰网
雷峰网
T
Tailwind CSS Blog
MongoDB | Blog
MongoDB | Blog
博客园 - 【当耐特】
博客园 - 聂微东
V
Visual Studio Blog
博客园_首页
Engineering at Meta
Engineering at Meta
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
The Cloudflare Blog
人人都是产品经理
人人都是产品经理
Apple Machine Learning Research
Apple Machine Learning Research
阮一峰的网络日志
阮一峰的网络日志
Microsoft Security Blog
Microsoft Security Blog
GbyAI
GbyAI
F
Fortinet All Blogs
C
Check Point Blog
罗磊的独立博客
H
Hackread – Cybersecurity News, Data Breaches, AI and More

Recent Commits to openclaw:main

test: merge chat side-result checks · openclaw/openclaw@ddd2c2a test: merge cron history checks · openclaw/openclaw@f7eb746 test: merge responsive navigation shell checks · openclaw/openclaw@c2e4b47 docs(changelog): add codex oauth fixes · openclaw/openclaw@628e6cd test: merge navigation routing cases · openclaw/openclaw@5d8cecb Tests: mock channel registry bundled fallback · openclaw/openclaw@2b08233 Secrets: avoid broad web search discovery for single plugin config · openclaw/openclaw@a464f59 test: merge config view browser checks · openclaw/openclaw@20cf511 fix(status): align oauth health with runtime · openclaw/openclaw@eed7116 feat: add macOS screen snapshots for monitor preview (#67954) thanks … · openclaw/openclaw@f377db1 fix: report shared auth scopes in hello-ok (#67810) thanks @BunsDev · openclaw/openclaw@0b6c39b Auto-reply: avoid eager bundled route fallback · openclaw/openclaw@3ea1bf4 Tests: narrow session binding contract setup · openclaw/openclaw@54e4e16 fix(macOS): enable undo/redo in webchat composer text input (#34962) · openclaw/openclaw@00951dc Tests: speed up channel setup promotion · openclaw/openclaw@82b529a Docs: refresh agent instructions · openclaw/openclaw@5775fe2 fix(auth): serialize OAuth refresh across agents to fix #26322 (#67876) · openclaw/openclaw@8e79080 test: allow ollama public surface boundary test · openclaw/openclaw@7d4f1a6 Docs: add test performance guardrails · openclaw/openclaw@89706d3 Tests: restore context-engine usage proof · openclaw/openclaw@e4c4f95 Tests: slim context engine runtime coverage · openclaw/openclaw@74c198f ci: retry failed custom checkouts · openclaw/openclaw@0ee5baf test: trim duplicate provider auth onboarding cases · openclaw/openclaw@1ffc02e matrix: fix sessions_spawn --thread subagent session spawning (#67643) · openclaw/openclaw@1ce2596 test: reduce auth choice fixture churn · openclaw/openclaw@857b9cd test: mock health status config boundaries · openclaw/openclaw@9d5ab4a test: mock onboard config io boundary · openclaw/openclaw@299694d test: mock legacy state plugin boundaries · openclaw/openclaw@2713089 test: mock channel install boundaries · openclaw/openclaw@b945248 test: mock doctor preview channel boundaries · openclaw/openclaw@b1a3ad4
fix(doctor): reinstall missing configured plugin payloads...
vincentkoc · 2026-05-03 · via Recent Commits to openclaw:main

@@ -791,7 +791,7 @@ describe("repairMissingConfiguredPluginInstalls", () => {

791791

expect(result.changes).toEqual(['Repaired missing configured plugin "demo".']);

792792

});

793793794-

it("reinstalls a known configured plugin when its recorded install path is missing", async () => {

794+

it("reinstalls a known configured plugin from the catalog when its recorded install path is missing", async () => {

795795

const records = {

796796

discord: {

797797

source: "npm",

@@ -809,6 +809,109 @@ describe("repairMissingConfiguredPluginInstalls", () => {

809809

],

810810

diagnostics: [],

811811

});

812+

mocks.listChannelPluginCatalogEntries.mockReturnValue([

813+

{

814+

id: "discord",

815+

pluginId: "discord",

816+

meta: { label: "Discord" },

817+

install: {

818+

npmSpec: "@openclaw/discord",

819+

},

820+

},

821+

]);

822+

mocks.installPluginFromNpmSpec.mockResolvedValueOnce({

823+

ok: true,

824+

pluginId: "discord",

825+

targetDir: "/tmp/openclaw-plugins/discord",

826+

version: "1.2.3",

827+

npmResolution: {

828+

name: "@openclaw/discord",

829+

version: "1.2.3",

830+

resolvedSpec: "@openclaw/discord@1.2.3",

831+

integrity: "sha512-discord",

832+

resolvedAt: "2026-05-01T00:00:00.000Z",

833+

},

834+

});

835+

mocks.updateNpmInstalledPlugins.mockResolvedValue({

836+

changed: false,

837+

config: {

838+

plugins: {

839+

installs: records,

840+

},

841+

},

842+

outcomes: [

843+

{

844+

pluginId: "discord",

845+

status: "skipped",

846+

message: "No update applied.",

847+

},

848+

],

849+

});

850+851+

const { repairMissingConfiguredPluginInstalls } =

852+

await import("./missing-configured-plugin-install.js");

853+

const result = await repairMissingConfiguredPluginInstalls({

854+

cfg: {

855+

plugins: {

856+

entries: {

857+

discord: { enabled: true },

858+

},

859+

},

860+

channels: {

861+

discord: { enabled: true },

862+

},

863+

},

864+

env: {},

865+

});

866+867+

expect(mocks.updateNpmInstalledPlugins).toHaveBeenCalledWith(

868+

expect.objectContaining({

869+

pluginIds: ["discord"],

870+

config: expect.objectContaining({

871+

plugins: expect.objectContaining({ installs: records }),

872+

}),

873+

}),

874+

);

875+

expect(mocks.installPluginFromNpmSpec).toHaveBeenCalledWith(

876+

expect.objectContaining({

877+

spec: "@openclaw/discord",

878+

expectedPluginId: "discord",

879+

}),

880+

);

881+

expect(mocks.writePersistedInstalledPluginIndexInstallRecords).toHaveBeenCalledWith(

882+

expect.objectContaining({

883+

discord: expect.objectContaining({ installPath: "/tmp/openclaw-plugins/discord" }),

884+

}),

885+

{ env: {} },

886+

);

887+

expect(result.changes).toEqual([

888+

'Installed missing configured plugin "discord" from @openclaw/discord.',

889+

]);

890+

});

891+892+

it("updates a known configured plugin when its installed manifest path still exists", async () => {

893+

const records = {

894+

discord: {

895+

source: "npm",

896+

spec: "@openclaw/discord",

897+

installPath: process.cwd(),

898+

},

899+

};

900+

mocks.loadInstalledPluginIndexInstallRecords.mockResolvedValue(records);

901+

mocks.loadPluginMetadataSnapshot.mockReturnValue({

902+

plugins: [

903+

{

904+

id: "discord",

905+

channels: ["discord"],

906+

},

907+

],

908+

diagnostics: [

909+

{

910+

pluginId: "discord",

911+

message: "manifest without channelConfigs metadata",

912+

},

913+

],

914+

});

812915

mocks.updateNpmInstalledPlugins.mockResolvedValue({

813916

changed: true,

814917

config: {

@@ -817,7 +920,7 @@ describe("repairMissingConfiguredPluginInstalls", () => {

817920

discord: {

818921

source: "npm",

819922

spec: "@openclaw/discord",

820-

installPath: "/tmp/openclaw-plugins/discord",

923+

installPath: process.cwd(),

821924

},

822925

},

823926

},

@@ -857,7 +960,7 @@ describe("repairMissingConfiguredPluginInstalls", () => {

857960

);

858961

expect(mocks.writePersistedInstalledPluginIndexInstallRecords).toHaveBeenCalledWith(

859962

expect.objectContaining({

860-

discord: expect.objectContaining({ installPath: "/tmp/openclaw-plugins/discord" }),

963+

discord: expect.objectContaining({ installPath: process.cwd() }),

861964

}),

862965

{ env: {} },

863966

);

@@ -907,7 +1010,7 @@ describe("repairMissingConfiguredPluginInstalls", () => {

9071010

discord: {

9081011

source: "npm",

9091012

spec: "@openclaw/discord",

910-

installPath: "/tmp/openclaw-plugins/discord",

1013+

installPath: process.cwd(),

9111014

},

9121015

},

9131016

},

@@ -949,7 +1052,7 @@ describe("repairMissingConfiguredPluginInstalls", () => {

9491052

);

9501053

expect(mocks.writePersistedInstalledPluginIndexInstallRecords).toHaveBeenCalledWith(

9511054

expect.objectContaining({

952-

discord: expect.objectContaining({ installPath: "/tmp/openclaw-plugins/discord" }),

1055+

discord: expect.objectContaining({ installPath: process.cwd() }),

9531056

}),

9541057

{ env: {} },

9551058

);

@@ -999,7 +1102,7 @@ describe("repairMissingConfiguredPluginInstalls", () => {

9991102

brave: {

10001103

source: "npm",

10011104

spec: "@openclaw/brave-plugin@beta",

1002-

installPath: "/tmp/openclaw-plugins/brave",

1105+

installPath: process.cwd(),

10031106

},

10041107

},

10051108

},

@@ -1038,7 +1141,7 @@ describe("repairMissingConfiguredPluginInstalls", () => {

10381141

);

10391142

expect(mocks.writePersistedInstalledPluginIndexInstallRecords).toHaveBeenCalledWith(

10401143

expect.objectContaining({

1041-

brave: expect.objectContaining({ installPath: "/tmp/openclaw-plugins/brave" }),

1144+

brave: expect.objectContaining({ installPath: process.cwd() }),

10421145

}),

10431146

{ env: {} },

10441147

);