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

推荐订阅源

C
Check Point Blog
IT之家
IT之家
V
Visual Studio Blog
The Cloudflare Blog
博客园 - 司徒正美
Jina AI
Jina AI
博客园_首页
阮一峰的网络日志
阮一峰的网络日志
美团技术团队
S
SegmentFault 最新的问题
博客园 - 聂微东
人人都是产品经理
人人都是产品经理
T
Tailwind CSS Blog
罗磊的独立博客
酷 壳 – CoolShell
酷 壳 – CoolShell
量子位
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
Hugging Face - Blog
Hugging Face - Blog
博客园 - 【当耐特】
博客园 - 三生石上(FineUI控件)
爱范儿
爱范儿
博客园 - Franky
Last Week in AI
Last Week in AI
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知

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(plugins): forward setChannelRuntime from non-bundled ...
openperf · 2026-05-07 · via Recent Commits to openclaw:main

@@ -5080,6 +5080,131 @@ module.exports = {

50805080

expect(fs.existsSync(runtimeMarker)).toBe(false);

50815081

});

508250825083+

it("invokes setChannelRuntime from a non-bundled setup entry for a configured deferred channel during startup Phase 1", () => {

5084+

// Regression test for #77779. When a configured external channel plugin opts into

5085+

// deferred full loading (startupDeferConfiguredChannelFullLoadUntilAfterListen) the

5086+

// loader runs in setup-runtime mode during Phase 1 (before gateway listen). In that

5087+

// phase api.registerChannel is active and writes the plugin into registry.channels,

5088+

// so the channel provider starts immediately — before Phase 2 runs register(). Any

5089+

// runtime initializer (e.g. setWeixinRuntime) that the provider polls for must

5090+

// therefore be invoked via setChannelRuntime in the setup entry. Before this fix,

5091+

// resolveSetupChannelRegistration silently dropped setChannelRuntime from non-bundled

5092+

// {plugin, setChannelRuntime} exports, leaving the runtime unset and causing

5093+

// waitForWeixinRuntime() to time out.

5094+

useNoBundledPlugins();

5095+

const pluginDir = makeTempDir();

5096+

const runtimeMarker = path.join(makeTempDir(), "deferred-configured-setup-runtime-applied.txt");

5097+5098+

fs.writeFileSync(

5099+

path.join(pluginDir, "package.json"),

5100+

JSON.stringify(

5101+

{

5102+

name: "@openclaw/non-bundled-deferred-setup-runtime-test",

5103+

openclaw: {

5104+

extensions: ["./index.cjs"],

5105+

setupEntry: "./setup-entry.cjs",

5106+

startup: {

5107+

deferConfiguredChannelFullLoadUntilAfterListen: true,

5108+

},

5109+

},

5110+

},

5111+

null,

5112+

2,

5113+

),

5114+

"utf-8",

5115+

);

5116+

fs.writeFileSync(

5117+

path.join(pluginDir, "openclaw.plugin.json"),

5118+

JSON.stringify(

5119+

{

5120+

id: "non-bundled-deferred-setup-runtime-test",

5121+

configSchema: { type: "object", properties: {} },

5122+

channels: ["non-bundled-deferred-setup-runtime-test"],

5123+

},

5124+

null,

5125+

2,

5126+

),

5127+

"utf-8",

5128+

);

5129+

fs.writeFileSync(

5130+

path.join(pluginDir, "index.cjs"),

5131+

`module.exports = {

5132+

id: "non-bundled-deferred-setup-runtime-test",

5133+

register(api) {

5134+

api.registerChannel({

5135+

plugin: {

5136+

id: "non-bundled-deferred-setup-runtime-test",

5137+

meta: {

5138+

id: "non-bundled-deferred-setup-runtime-test",

5139+

label: "Non-Bundled Deferred Setup Runtime Test",

5140+

selectionLabel: "Non-Bundled Deferred Setup Runtime Test",

5141+

docsPath: "/channels/non-bundled-deferred-setup-runtime-test",

5142+

blurb: "full channel entry",

5143+

},

5144+

capabilities: { chatTypes: ["direct"] },

5145+

config: { listAccountIds: () => ["default"], resolveAccount: () => ({ accountId: "default", token: "configured" }) },

5146+

outbound: { deliveryMode: "direct" },

5147+

},

5148+

});

5149+

},

5150+

};`,

5151+

"utf-8",

5152+

);

5153+

fs.writeFileSync(

5154+

path.join(pluginDir, "setup-entry.cjs"),

5155+

`module.exports = {

5156+

plugin: {

5157+

id: "non-bundled-deferred-setup-runtime-test",

5158+

meta: {

5159+

id: "non-bundled-deferred-setup-runtime-test",

5160+

label: "Non-Bundled Deferred Setup Runtime Test",

5161+

selectionLabel: "Non-Bundled Deferred Setup Runtime Test",

5162+

docsPath: "/channels/non-bundled-deferred-setup-runtime-test",

5163+

blurb: "setup entry",

5164+

},

5165+

capabilities: { chatTypes: ["direct"] },

5166+

config: { listAccountIds: () => ["default"], resolveAccount: () => ({ accountId: "default", token: "configured" }) },

5167+

outbound: { deliveryMode: "direct" },

5168+

},

5169+

setChannelRuntime: () => {

5170+

require("node:fs").writeFileSync(${JSON.stringify(runtimeMarker)}, "applied", "utf-8");

5171+

},

5172+

};`,

5173+

"utf-8",

5174+

);

5175+5176+

// Phase 1: preferSetupRuntimeForChannelPlugins=true simulates gateway startup when

5177+

// at least one deferred configured channel plugin is present. The configured channel

5178+

// opts into deferral, so setup-runtime mode is used. setup-entry.cjs is loaded and

5179+

// setChannelRuntime must be invoked. The channel is also written into registry.channels

5180+

// (runtimeChannel=true in setup-runtime), so the provider starts in Phase 1.

5181+

const registry = loadOpenClawPlugins({

5182+

cache: false,

5183+

preferSetupRuntimeForChannelPlugins: true,

5184+

config: {

5185+

channels: {

5186+

"non-bundled-deferred-setup-runtime-test": {

5187+

enabled: true,

5188+

token: "configured",

5189+

},

5190+

},

5191+

plugins: {

5192+

load: { paths: [pluginDir] },

5193+

allow: ["non-bundled-deferred-setup-runtime-test"],

5194+

},

5195+

},

5196+

});

5197+5198+

// setChannelRuntime must have been called so that any runtime initializer the

5199+

// provider polls for (e.g. waitForWeixinRuntime) is satisfied before the provider

5200+

// times out.

5201+

expect(fs.existsSync(runtimeMarker)).toBe(true);

5202+

// The channel is registered in registry.channels during Phase 1 (not deferred to

5203+

// Phase 2), confirming the provider would start and need setChannelRuntime.

5204+

expect(registry.channels).toHaveLength(1);

5205+

expect(registry.channels[0]?.plugin.id).toBe("non-bundled-deferred-setup-runtime-test");

5206+

});

5207+50835208

it("isolates loadSetupPlugin errors as per-plugin diagnostics instead of crashing registry load", () => {

50845209

useNoBundledPlugins();

50855210

const pluginDir = makeTempDir();