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

推荐订阅源

V
V2EX
人人都是产品经理
人人都是产品经理
WordPress大学
WordPress大学
博客园 - Franky
小众软件
小众软件
酷 壳 – CoolShell
酷 壳 – CoolShell
Apple Machine Learning Research
Apple Machine Learning Research
爱范儿
爱范儿
IT之家
IT之家
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
V
Visual Studio Blog
S
SegmentFault 最新的问题
美团技术团队
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
有赞技术团队
有赞技术团队
B
Blog RSS Feed
Last Week in AI
Last Week in AI
Jina AI
Jina AI
博客园 - 司徒正美
The Cloudflare Blog
博客园_首页
博客园 - 聂微东
宝玉的分享
宝玉的分享
大猫的无限游戏
大猫的无限游戏

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(gateway): cancel delayed maintenance on shutdown · op...
vincentkoc · 2026-05-06 · via Recent Commits to openclaw:main
Original file line numberDiff line numberDiff line change

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

8686
8787

### Fixes

8888
89+

- Gateway/shutdown: cancel delayed post-ready maintenance during close and suppress maintenance/cron startup after quick restarts, preventing orphaned background timers. Thanks @vincentkoc.

8990

- Agents/generated media: treat attachment-style message tool actions as completed chat sends, preventing duplicate fallback media posts when generated files were already uploaded.

9091

- Control UI/sessions: show each session's agent runtime in the Sessions table and allow filtering by runtime labels, matching the Agents panel runtime wording. Thanks @vincentkoc.

9192

- Discord/streaming: show live reasoning text in progress drafts instead of a bare `Reasoning` status line.

Original file line numberDiff line numberDiff line change

@@ -56,9 +56,24 @@ describe("gateway startup import boundaries", () => {

5656

const closeStart = serverImpl.indexOf("close: async (opts)");

5757

const hookStart = serverImpl.indexOf("runGlobalGatewayStopSafely", closeStart);

5858

const markStart = serverImpl.indexOf("markClosePreludeStarted();", closeStart);

59+

const markHelperStart = serverImpl.indexOf("const markClosePreludeStarted = () => {");

60+

const markHelperEnd = serverImpl.indexOf("};", markHelperStart);

61+

const postReadyStart = serverImpl.indexOf("scheduleGatewayPostReadyMaintenance({");

62+

const postReadyEnd = serverImpl.indexOf("});", postReadyStart);

63+

const postReadyBlock = serverImpl.slice(postReadyStart, postReadyEnd);

5964
6065

expect(closeStart).toBeGreaterThan(-1);

6166

expect(markStart).toBeGreaterThan(closeStart);

6267

expect(markStart).toBeLessThan(hookStart);

68+

expect(markHelperStart).toBeGreaterThan(-1);

69+

expect(serverImpl.slice(markHelperStart, markHelperEnd)).toContain(

70+

"clearPostReadyMaintenanceTimer();",

71+

);

72+

expect(postReadyStart).toBeGreaterThan(-1);

73+

expect(postReadyBlock).toContain("isClosing: () => closePreludeStarted");

74+

expect(postReadyBlock).toContain("if (closePreludeStarted)");

75+

expect(postReadyBlock).toContain(

76+

"shouldStartCron: () => !closePreludeStarted && !gatewayCronStartHandled",

77+

);

6378

});

6479

});

Original file line numberDiff line numberDiff line change

@@ -1524,14 +1524,28 @@ export async function startGatewayServer(

15241524

onStarted: () => {

15251525

postReadyMaintenanceTimer = null;

15261526

},

1527-

startMaintenance: earlyRuntime.startMaintenance,

1527+

startMaintenance: async () => {

1528+

if (closePreludeStarted) {

1529+

return null;

1530+

}

1531+

return earlyRuntime.startMaintenance();

1532+

},

15281533

applyMaintenance: (maintenance) => {

1534+

if (closePreludeStarted) {

1535+

clearInterval(maintenance.tickInterval);

1536+

clearInterval(maintenance.healthInterval);

1537+

clearInterval(maintenance.dedupeCleanup);

1538+

if (maintenance.mediaCleanup) {

1539+

clearInterval(maintenance.mediaCleanup);

1540+

}

1541+

return;

1542+

}

15291543

runtimeState.tickInterval = maintenance.tickInterval;

15301544

runtimeState.healthInterval = maintenance.healthInterval;

15311545

runtimeState.dedupeCleanup = maintenance.dedupeCleanup;

15321546

runtimeState.mediaCleanup = maintenance.mediaCleanup;

15331547

},

1534-

shouldStartCron: () => !gatewayCronStartHandled,

1548+

shouldStartCron: () => !closePreludeStarted && !gatewayCronStartHandled,

15351549

markCronStartHandled: () => {

15361550

gatewayCronStartHandled = true;

15371551

},