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

推荐订阅源

博客园_首页
Blog — PlanetScale
Blog — PlanetScale
腾讯CDC
aimingoo的专栏
aimingoo的专栏
Microsoft Azure Blog
Microsoft Azure Blog
A
About on SuperTechFans
J
Java Code Geeks
G
Google Developers Blog
N
Netflix TechBlog - Medium
Vercel News
Vercel News
Y
Y Combinator Blog
Recent Announcements
Recent Announcements
I
InfoQ
Stack Overflow Blog
Stack Overflow Blog
酷 壳 – CoolShell
酷 壳 – CoolShell
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
T
The Blog of Author Tim Ferriss
罗磊的独立博客
GbyAI
GbyAI
小众软件
小众软件
大猫的无限游戏
大猫的无限游戏
WordPress大学
WordPress大学
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & 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: normalize per-agent gemini config refs · openclaw/op...
steipete · 2026-05-13 · via Recent Commits to openclaw:main
Original file line numberDiff line numberDiff line change

@@ -51,6 +51,7 @@ Docs: https://docs.openclaw.ai

5151

- Google/Gemini: normalize retired Gemini 3 Pro Preview ids in provider catalog rows when API-key onboarding only reapplies the agent default, so emitted config keeps testing `google/gemini-3.1-pro-preview`.

5252

- Google/Gemini: canonicalize provider-qualified retired Gemini 3 Pro Preview refs during Google forward-compatible model resolution, so emitted config uses `google/gemini-3.1-pro-preview` for Gemini 3.1 testing.

5353

- Google/Gemini: normalize proxy-prefixed retired Gemini 3 Pro Preview catalog rows, so emitted configs use `google/gemini-3.1-pro-preview` for Gemini 3.1 testing.

54+

- Google/Gemini: normalize retired Gemini 3 Pro Preview ids inside per-agent model overrides before writing config, so agent-specific config emits `google/gemini-3.1-pro-preview` for Gemini 3.1 testing.

5455

- Docs/subagents: document `agents.defaults.subagents.announceTimeoutMs` in the sub-agent and configuration references. (#75509) Thanks @akrimm702.

5556

- Cron: add direct `cron.get`, `openclaw cron get <id>`, and agent-tool `get` support for inspecting one stored cron job by id. (#75117) Thanks @samzong.

5657

- Agents/tools: add per-sender tool policies with canonical channel-scoped sender keys, so operators can restrict dangerous tools by requester identity across global, agent, group, core, bundled, and plugin tool surfaces. (#66933) Thanks @JerranC.

Original file line numberDiff line numberDiff line change

@@ -183,6 +183,20 @@ describe("config io write prepare", () => {

183183

},

184184

},

185185

},

186+

list: [

187+

{

188+

id: "ops",

189+

model: {

190+

primary: "google/gemini-3-pro-preview",

191+

fallbacks: ["google/gemini-3-pro-preview"],

192+

},

193+

models: {

194+

"google/gemini-3-pro-preview": {

195+

alias: "Ops Gemini",

196+

},

197+

},

198+

},

199+

],

186200

},

187201

gateway: { port: 18789 },

188202

};

@@ -199,6 +213,20 @@ describe("config io write prepare", () => {

199213

},

200214

},

201215

},

216+

list: [

217+

{

218+

id: "ops",

219+

model: {

220+

primary: "google/gemini-3.1-pro-preview",

221+

fallbacks: ["google/gemini-3.1-pro-preview"],

222+

},

223+

models: {

224+

"google/gemini-3.1-pro-preview": {

225+

alias: "Ops Gemini",

226+

},

227+

},

228+

},

229+

],

202230

},

203231

gateway: { port: 18789 },

204232

};

@@ -220,6 +248,15 @@ describe("config io write prepare", () => {

220248

alias: "Gemini",

221249

},

222250

});

251+

expect(persisted.agents?.list?.[0]?.model).toEqual({

252+

primary: "google/gemini-3.1-pro-preview",

253+

fallbacks: ["google/gemini-3.1-pro-preview"],

254+

});

255+

expect(persisted.agents?.list?.[0]?.models).toEqual({

256+

"google/gemini-3.1-pro-preview": {

257+

alias: "Ops Gemini",

258+

},

259+

});

223260

expect(persisted.gateway?.port).toBe(18888);

224261

});

225262
Original file line numberDiff line numberDiff line change

@@ -355,6 +355,39 @@ function normalizeAgentDefaultModelRefsForWrite(config: unknown): unknown {

355355

return next;

356356

}

357357
358+

function normalizeAgentListModelRefsForWrite(config: unknown): unknown {

359+

const list = getPathValue(config, ["agents", "list"]);

360+

if (!Array.isArray(list)) {

361+

return config;

362+

}

363+
364+

let mutated = false;

365+

const nextList = list.map((agent) => {

366+

if (!isRecord(agent)) {

367+

return agent;

368+

}

369+
370+

let nextAgent = agent;

371+

if (Object.prototype.hasOwnProperty.call(agent, "model")) {

372+

const normalizedModel = normalizeAgentModelConfigForWrite(agent.model);

373+

if (normalizedModel !== agent.model) {

374+

nextAgent = { ...nextAgent, model: normalizedModel };

375+

mutated = true;

376+

}

377+

}

378+

if (isRecord(agent.models)) {

379+

const normalizedModels = normalizeAgentModelMapForConfig(agent.models);

380+

if (normalizedModels !== agent.models) {

381+

nextAgent = { ...nextAgent, models: normalizedModels };

382+

mutated = true;

383+

}

384+

}

385+

return nextAgent;

386+

});

387+
388+

return mutated ? setPathValue(config, ["agents", "list"], nextList) : config;

389+

}

390+
358391

function normalizeModelProviderCatalogRefsForWrite(config: unknown): unknown {

359392

const providers = getPathValue(config, ["models", "providers"]);

360393

if (!isRecord(providers)) {

@@ -395,7 +428,9 @@ function normalizeModelProviderCatalogRefsForWrite(config: unknown): unknown {

395428

}

396429
397430

function normalizeModelRefsForWrite(config: unknown): unknown {

398-

return normalizeModelProviderCatalogRefsForWrite(normalizeAgentDefaultModelRefsForWrite(config));

431+

return normalizeModelProviderCatalogRefsForWrite(

432+

normalizeAgentListModelRefsForWrite(normalizeAgentDefaultModelRefsForWrite(config)),

433+

);

399434

}

400435
401436

function preserveUntouchedIncludes(params: {