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

推荐订阅源

让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
MyScale Blog
MyScale Blog
U
Unit 42
M
MIT News - Artificial intelligence
小众软件
小众软件
P
Proofpoint News Feed
雷峰网
雷峰网
L
LangChain Blog
S
SegmentFault 最新的问题
腾讯CDC
F
Fortinet All Blogs
A
About on SuperTechFans
WordPress大学
WordPress大学
Vercel News
Vercel News
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
G
Google Developers Blog
大猫的无限游戏
大猫的无限游戏
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
D
Docker
N
Netflix TechBlog - Medium
Apple Machine Learning Research
Apple Machine Learning Research
Recent Announcements
Recent Announcements
D
DataBreaches.Net
Stack Overflow Blog
Stack Overflow 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
test: pin gateway doctor notes · openclaw/openclaw@0d8d350
shakkernerd · 2026-05-11 · via Recent Commits to openclaw:main

@@ -1,10 +1,14 @@

11

import { afterEach, beforeAll, beforeEach, describe, expect, it, vi } from "vitest";

2+

import { formatCliCommand } from "../cli/command-format.js";

23

import type { ExtraGatewayService } from "../daemon/inspect.js";

34

import * as launchd from "../daemon/launchd.js";

45

import type { GatewayRestartHandoff } from "../infra/restart-handoff.js";

56

import { withEnvAsync } from "../test-utils/env.js";

67

import { createDoctorPrompter } from "./doctor-prompter.js";

7-

import { EXTERNAL_SERVICE_REPAIR_NOTE } from "./doctor-service-repair-policy.js";

8+

import {

9+

EXTERNAL_SERVICE_REPAIR_NOTE,

10+

SERVICE_REPAIR_POLICY_ENV,

11+

} from "./doctor-service-repair-policy.js";

812913

const service = vi.hoisted(() => ({

1014

isLoaded: vi.fn(),

@@ -164,6 +168,7 @@ describe("maybeRepairGatewayDaemon", () => {

164168

});

165169166170

afterEach(() => {

171+

vi.useRealTimers();

167172

if (originalPlatformDescriptor) {

168173

Object.defineProperty(process, "platform", originalPlatformDescriptor);

169174

}

@@ -266,6 +271,8 @@ describe("maybeRepairGatewayDaemon", () => {

266271

});

267272268273

it("reports recent restart handoffs during deep doctor", async () => {

274+

vi.useFakeTimers();

275+

vi.setSystemTime(40_000);

269276

setPlatform("linux");

270277

service.readCommand.mockResolvedValueOnce({

271278

programArguments: ["/bin/node", "cli", "gateway"],

@@ -306,11 +313,7 @@ describe("maybeRepairGatewayDaemon", () => {

306313

expect(handoffEnv?.OPENCLAW_STATE_DIR).toBe("/tmp/openclaw-service");

307314

expect(handoffEnv?.OPENCLAW_CONFIG_PATH).toBe("/tmp/openclaw-service/openclaw.json");

308315

expect(note).toHaveBeenCalledWith(

309-

expect.stringContaining("Recent restart handoff: full-process via systemd"),

310-

"Gateway",

311-

);

312-

expect(note).toHaveBeenCalledWith(

313-

expect.stringContaining("reason=plugin source changed"),

316+

"Recent restart handoff: full-process via systemd; source=plugin-change; reason=plugin source changed; pid=12345; age=30s; expiresIn=30s",

314317

"Gateway",

315318

);

316319

});

@@ -382,7 +385,7 @@ describe("maybeRepairGatewayDaemon", () => {

382385

expect(service.install).not.toHaveBeenCalled();

383386

expect(service.restart).not.toHaveBeenCalled();

384387

expect(note).toHaveBeenCalledWith(

385-

expect.stringContaining("openclaw gateway install"),

388+

`Run ${formatCliCommand("openclaw gateway install")} when you want to install the gateway service.`,

386389

"Gateway",

387390

);

388391

});

@@ -428,7 +431,13 @@ describe("maybeRepairGatewayDaemon", () => {

428431

expect(service.install).not.toHaveBeenCalled();

429432

expect(service.restart).not.toHaveBeenCalled();

430433

expect(note).toHaveBeenCalledWith(

431-

expect.stringContaining("System-level OpenClaw gateway service detected"),

434+

[

435+

"System-level OpenClaw gateway service detected while the user gateway service is not installed.",

436+

"- openclaw-gateway.service (unit: /etc/systemd/system/openclaw-gateway.service)",

437+

"OpenClaw will not install a second user-level gateway service automatically.",

438+

"Run `openclaw gateway status --deep` or `openclaw doctor --deep` to inspect duplicate services.",

439+

`Set ${SERVICE_REPAIR_POLICY_ENV}=external if a system supervisor owns the gateway lifecycle.`,

440+

].join("\n"),

432441

"Gateway",

433442

);

434443

});