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

推荐订阅源

The Cloudflare Blog
小众软件
小众软件
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
T
Tailwind CSS Blog
WordPress大学
WordPress大学
有赞技术团队
有赞技术团队
博客园 - 司徒正美
V
Visual Studio Blog
G
Google Developers Blog
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
月光博客
月光博客
aimingoo的专栏
aimingoo的专栏
博客园_首页
Blog — PlanetScale
Blog — PlanetScale
博客园 - 聂微东
S
SegmentFault 最新的问题
T
The Blog of Author Tim Ferriss
D
Docker
Vercel News
Vercel News
Recent Announcements
Recent Announcements
Last Week in AI
Last Week in AI
爱范儿
爱范儿
J
Java Code Geeks
大猫的无限游戏
大猫的无限游戏

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(control-ui): preserve loopback client version labels ...
steipete · 2026-04-27 · via Recent Commits to openclaw:main
Original file line numberDiff line numberDiff line change

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

2020
2121

### Fixes

2222
23+

- Control UI/Gateway: preserve WebChat client version labels across localhost, 127.0.0.1, and IPv6 loopback aliases on the same port, avoiding misleading `vcontrol-ui` connection logs while investigating duplicate-message reports. Refs #72753 and #72742. Thanks @LumenFromTheFuture and @allesgutefy.

2324

- Memory-core: run one-shot memory CLI commands through transient builtin and QMD managers so `memory index`, `memory status --index`, and `memory search` no longer start long-lived file watchers that can hit macOS `EMFILE` limits. Fixes #59101; carries forward #49851. Thanks @mbear469210-coder and @maoyuanxue.

2425

- Memory-core: re-resolve the active runtime config whenever `memory_search` or `memory_get` executes, so provider changes made by `config.patch` stop leaving stale embedding backends behind in existing tool instances. Fixes #61098. Thanks @BradGroux and @Linux2010.

2526

- WebChat: keep bare `/new` and `/reset` startup instructions out of visible chat history while preserving `/reset <note>` as user-visible transcript text. Fixes #72369. Thanks @collynes and @haishmg.

Original file line numberDiff line numberDiff line change

@@ -1025,6 +1025,33 @@ describe("resolveControlUiClientVersion", () => {

10251025

).toBe("2026.3.7");

10261026

});

10271027
1028+

it("returns serverVersion for loopback aliases on the same port", () => {

1029+

expect(

1030+

resolveControlUiClientVersion({

1031+

gatewayUrl: "ws://127.0.0.1:18789",

1032+

serverVersion: "2026.4.24",

1033+

pageUrl: "http://localhost:18789/chat",

1034+

}),

1035+

).toBe("2026.4.24");

1036+

expect(

1037+

resolveControlUiClientVersion({

1038+

gatewayUrl: "ws://[::1]:18789",

1039+

serverVersion: "2026.4.24",

1040+

pageUrl: "http://127.0.0.1:18789/chat",

1041+

}),

1042+

).toBe("2026.4.24");

1043+

});

1044+
1045+

it("omits serverVersion for loopback aliases on different ports", () => {

1046+

expect(

1047+

resolveControlUiClientVersion({

1048+

gatewayUrl: "ws://127.0.0.1:18789",

1049+

serverVersion: "2026.4.24",

1050+

pageUrl: "http://localhost:19889/chat",

1051+

}),

1052+

).toBeUndefined();

1053+

});

1054+
10281055

it("omits serverVersion for cross-origin targets", () => {

10291056

expect(

10301057

resolveControlUiClientVersion({

Original file line numberDiff line numberDiff line change

@@ -265,7 +265,7 @@ export function resolveControlUiClientVersion(params: {

265265

const page = new URL(pageUrl);

266266

const gateway = new URL(params.gatewayUrl, page);

267267

const allowedProtocols = new Set(["ws:", "wss:", "http:", "https:"]);

268-

if (!allowedProtocols.has(gateway.protocol) || gateway.host !== page.host) {

268+

if (!allowedProtocols.has(gateway.protocol) || !isSameControlUiVersionEndpoint(page, gateway)) {

269269

return undefined;

270270

}

271271

return serverVersion;

@@ -274,6 +274,44 @@ export function resolveControlUiClientVersion(params: {

274274

}

275275

}

276276
277+

function isSameControlUiVersionEndpoint(page: URL, gateway: URL): boolean {

278+

if (gateway.host === page.host) {

279+

return true;

280+

}

281+

return (

282+

isLoopbackHostname(page.hostname) &&

283+

isLoopbackHostname(gateway.hostname) &&

284+

resolveUrlEffectivePort(page) === resolveUrlEffectivePort(gateway)

285+

);

286+

}

287+
288+

function isLoopbackHostname(hostname: string): boolean {

289+

const normalized = hostname.trim().toLowerCase().replace(/^\[/, "").replace(/\]$/, "");

290+

return (

291+

normalized === "localhost" ||

292+

normalized === "::1" ||

293+

normalized === "0:0:0:0:0:0:0:1" ||

294+

normalized === "127.0.0.1" ||

295+

normalized.startsWith("127.")

296+

);

297+

}

298+
299+

function resolveUrlEffectivePort(url: URL): string {

300+

if (url.port) {

301+

return url.port;

302+

}

303+

switch (url.protocol) {

304+

case "http:":

305+

case "ws:":

306+

return "80";

307+

case "https:":

308+

case "wss:":

309+

return "443";

310+

default:

311+

return "";

312+

}

313+

}

314+
277315

function normalizeSessionKeyForDefaults(

278316

value: string | undefined,

279317

defaults: SessionDefaultsSnapshot,