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

推荐订阅源

钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
WordPress大学
WordPress大学
T
Tailwind CSS Blog
V
Visual Studio Blog
月光博客
月光博客
Hugging Face - Blog
Hugging Face - Blog
小众软件
小众软件
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
博客园 - Franky
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
Last Week in AI
Last Week in AI
阮一峰的网络日志
阮一峰的网络日志
量子位
有赞技术团队
有赞技术团队
酷 壳 – CoolShell
酷 壳 – CoolShell
Apple Machine Learning Research
Apple Machine Learning Research
博客园_首页
Jina AI
Jina AI
雷峰网
雷峰网
博客园 - 【当耐特】
博客园 - 叶小钗
美团技术团队
宝玉的分享
宝玉的分享
IT之家
IT之家

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: avoid startup auto-enable runtime defaults · opencla...
shakkernerd · 2026-04-27 · via Recent Commits to openclaw:main

@@ -354,48 +354,91 @@ function collectConfiguredPluginEntryIds(cfg: OpenClawConfig): string[] {

354354

.filter(Boolean);

355355

}

356356357+

function hasOwnPluginEntry(cfg: OpenClawConfig, pluginId: string): boolean {

358+

const entries = cfg.plugins?.entries;

359+

return !!entries && typeof entries === "object" && Object.hasOwn(entries, pluginId);

360+

}

361+362+

function hasNonDisabledPluginEntry(cfg: OpenClawConfig, pluginId: string): boolean {

363+

if (!hasOwnPluginEntry(cfg, pluginId)) {

364+

return false;

365+

}

366+

const entry = cfg.plugins?.entries?.[pluginId];

367+

return !isRecord(entry) || entry.enabled !== false;

368+

}

369+370+

function hasBrowserSetupAutoEnableRelevantConfig(cfg: OpenClawConfig): boolean {

371+

if (isRecord(cfg.browser) && cfg.browser.enabled !== false) {

372+

return true;

373+

}

374+

if (hasNonDisabledPluginEntry(cfg, "browser")) {

375+

return true;

376+

}

377+

return hasBrowserToolReference(cfg);

378+

}

379+380+

function hasAcpxSetupAutoEnableRelevantConfig(cfg: OpenClawConfig): boolean {

381+

if (!isRecord(cfg.acp)) {

382+

return false;

383+

}

384+

const backend = normalizeOptionalLowercaseString(cfg.acp.backend);

385+

const configured =

386+

cfg.acp.enabled === true ||

387+

(isRecord(cfg.acp.dispatch) && cfg.acp.dispatch.enabled === true) ||

388+

backend === "acpx";

389+

return configured && (!backend || backend === "acpx");

390+

}

391+392+

function hasXaiSetupAutoEnableRelevantConfig(cfg: OpenClawConfig): boolean {

393+

const pluginConfig = cfg.plugins?.entries?.xai?.config;

394+

return (

395+

(isRecord(pluginConfig) &&

396+

(isRecord(pluginConfig.xSearch) || isRecord(pluginConfig.codeExecution))) ||

397+

(isRecord(cfg.tools?.web) && isRecord((cfg.tools.web as Record<string, unknown>).x_search))

398+

);

399+

}

400+357401

function resolveRelevantSetupAutoEnablePluginIds(cfg: OpenClawConfig): string[] {

358402

const pluginIds = new Set<string>(collectConfiguredPluginEntryIds(cfg));

359-

if (

360-

isRecord(cfg.browser) ||

361-

isRecord(cfg.plugins?.entries?.browser) ||

362-

hasBrowserToolReference(cfg)

363-

) {

403+

if (hasBrowserSetupAutoEnableRelevantConfig(cfg)) {

364404

pluginIds.add("browser");

365405

}

366-

if (isRecord(cfg.acp) || isRecord(cfg.plugins?.entries?.acpx)) {

406+

if (hasAcpxSetupAutoEnableRelevantConfig(cfg)) {

367407

pluginIds.add("acpx");

368408

}

369-

if (

370-

isRecord(cfg.plugins?.entries?.xai) ||

371-

(isRecord(cfg.tools?.web) && isRecord((cfg.tools.web as Record<string, unknown>).x_search))

372-

) {

409+

if (hasXaiSetupAutoEnableRelevantConfig(cfg)) {

373410

pluginIds.add("xai");

374411

}

375412

return [...pluginIds].toSorted((left, right) => left.localeCompare(right));

376413

}

377414378415

function hasSetupAutoEnableRelevantConfig(cfg: OpenClawConfig): boolean {

379-

const entries = cfg.plugins?.entries;

380-

if (isRecord(cfg.browser) || isRecord(cfg.acp) || hasBrowserToolReference(cfg)) {

381-

return true;

382-

}

383-

if (isRecord(entries?.browser) || isRecord(entries?.acpx) || isRecord(entries?.xai)) {

384-

return true;

385-

}

386-

if (isRecord(cfg.tools?.web) && isRecord((cfg.tools.web as Record<string, unknown>).x_search)) {

387-

return true;

388-

}

389-

return hasConfiguredPluginConfigEntry(cfg);

416+

return (

417+

hasBrowserSetupAutoEnableRelevantConfig(cfg) ||

418+

hasAcpxSetupAutoEnableRelevantConfig(cfg) ||

419+

hasXaiSetupAutoEnableRelevantConfig(cfg) ||

420+

hasConfiguredPluginConfigEntry(cfg)

421+

);

390422

}

391423392424

function hasPluginEntries(cfg: OpenClawConfig): boolean {

393425

const entries = cfg.plugins?.entries;

394426

return !!entries && typeof entries === "object" && Object.keys(entries).length > 0;

395427

}

396428397-

function hasPluginAllowlistWithEntries(cfg: OpenClawConfig): boolean {

398-

return Array.isArray(cfg.plugins?.allow) && cfg.plugins.allow.length > 0 && hasPluginEntries(cfg);

429+

function hasPluginAllowlistWithMaterialEntries(cfg: OpenClawConfig): boolean {

430+

if (

431+

!Array.isArray(cfg.plugins?.allow) ||

432+

cfg.plugins.allow.length === 0 ||

433+

!hasPluginEntries(cfg)

434+

) {

435+

return false;

436+

}

437+

const entries = cfg.plugins?.entries;

438+

if (!entries || typeof entries !== "object") {

439+

return false;

440+

}

441+

return Object.values(entries).some(hasMaterialPluginEntryConfig);

399442

}

400443401444

function hasConfiguredProviderModelOrHarness(cfg: OpenClawConfig, env: NodeJS.ProcessEnv): boolean {

@@ -412,7 +455,7 @@ function hasConfiguredProviderModelOrHarness(cfg: OpenClawConfig, env: NodeJS.Pr

412455

}

413456414457

function configMayNeedPluginManifestRegistry(cfg: OpenClawConfig, env: NodeJS.ProcessEnv): boolean {

415-

if (hasPluginAllowlistWithEntries(cfg)) {

458+

if (hasPluginAllowlistWithMaterialEntries(cfg)) {

416459

return true;

417460

}

418461

if (hasConfiguredPluginConfigEntry(cfg)) {

@@ -438,7 +481,7 @@ export function configMayNeedPluginAutoEnable(

438481

cfg: OpenClawConfig,

439482

env: NodeJS.ProcessEnv,

440483

): boolean {

441-

if (hasPluginAllowlistWithEntries(cfg)) {

484+

if (hasPluginAllowlistWithMaterialEntries(cfg)) {

442485

return true;

443486

}

444487

if (hasConfiguredPluginConfigEntry(cfg)) {