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

推荐订阅源

月光博客
月光博客
Stack Overflow Blog
Stack Overflow Blog
L
LangChain Blog
Jina AI
Jina AI
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
雷峰网
雷峰网
T
Tailwind CSS Blog
MongoDB | Blog
MongoDB | Blog
博客园 - 【当耐特】
博客园 - 聂微东
V
Visual Studio Blog
博客园_首页
Engineering at Meta
Engineering at Meta
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
The Cloudflare Blog
人人都是产品经理
人人都是产品经理
Apple Machine Learning Research
Apple Machine Learning Research
阮一峰的网络日志
阮一峰的网络日志
Microsoft Security Blog
Microsoft Security Blog
GbyAI
GbyAI
F
Fortinet All Blogs
C
Check Point Blog
罗磊的独立博客
H
Hackread – Cybersecurity News, Data Breaches, AI and 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(update): avoid broad tag fetches for dev updates (#84...
rubencu · 2026-05-24 · via Recent Commits to openclaw:main

@@ -386,7 +386,7 @@ describe("runGatewayUpdate", () => {

386386

{ name: "target ref", options: { devTargetRef: "main" } },

387387

] as const)("stops dev update when fetch fails before resolving $name", async ({ options }) => {

388388

await setupGitCheckout();

389-

const fetchCommand = `git -C ${tempDir} fetch --all --prune --tags`;

389+

const fetchCommand = `git -C ${tempDir} fetch --all --prune --no-tags`;

390390

const { runner, calls } = createRunner({

391391

...buildGitWorktreeProbeResponses(),

392392

[fetchCommand]: {

@@ -403,6 +403,102 @@ describe("runGatewayUpdate", () => {

403403

expect(calls.slice(calls.indexOf(fetchCommand) + 1)).toStrictEqual([]);

404404

});

405405406+

it("does not fetch tags for dev updates", async () => {

407+

await setupGitPackageManagerFixture();

408+

const upstreamSha = "upstream123";

409+

const doctorNodePath = await resolveStableNodePath(process.execPath);

410+

const doctorCommand = `${doctorNodePath} ${path.join(tempDir, "openclaw.mjs")} doctor --non-interactive --fix`;

411+

const { runner, calls } = createRunner({

412+

...buildGitWorktreeProbeResponses(),

413+

[`git -C ${tempDir} fetch --all --prune --no-tags`]: { stdout: "" },

414+

[`git -C ${tempDir} rev-parse --abbrev-ref --symbolic-full-name @{upstream}`]: {

415+

stdout: "origin/main",

416+

},

417+

[`git -C ${tempDir} rev-parse @{upstream}`]: { stdout: upstreamSha },

418+

[`git -C ${tempDir} rev-list --max-count=10 ${upstreamSha}`]: {

419+

stdout: `${upstreamSha}\n`,

420+

},

421+

[`git -C ${tempDir} rebase ${upstreamSha}`]: { stdout: "" },

422+

"pnpm --version": { stdout: "10.0.0" },

423+

"pnpm install": { stdout: "" },

424+

"pnpm build": { stdout: "" },

425+

"pnpm ui:build": { stdout: "" },

426+

[doctorCommand]: { stdout: "" },

427+

});

428+429+

const result = await runWithRunner(runner, { channel: "dev" });

430+431+

expect(result.status).toBe("ok");

432+

expect(calls).toContain(`git -C ${tempDir} fetch --all --prune --no-tags`);

433+

expect(calls).not.toContain(`git -C ${tempDir} fetch --all --prune --tags`);

434+

});

435+436+

it("fetches only the requested tag for explicit dev tag target refs", async () => {

437+

await setupGitPackageManagerFixture();

438+

const targetSha = "2222222222222222222222222222222222222222";

439+

const doctorNodePath = await resolveStableNodePath(process.execPath);

440+

const doctorCommand = `${doctorNodePath} ${path.join(tempDir, "openclaw.mjs")} doctor --non-interactive --fix`;

441+

const { runner, calls } = createRunner({

442+

...buildGitWorktreeProbeResponses(),

443+

[`git -C ${tempDir} fetch --all --prune --no-tags`]: { stdout: "" },

444+

[`git -C ${tempDir} remote`]: { stdout: "origin\n" },

445+

[`git -C ${tempDir} fetch origin +refs/tags/v2026.5.19-beta.2:refs/tags/v2026.5.19-beta.2`]: {

446+

stdout: "",

447+

},

448+

[`git -C ${tempDir} rev-parse refs/tags/v2026.5.19-beta.2^{}`]: {

449+

stdout: `${targetSha}\n`,

450+

},

451+

[`git -C ${tempDir} rev-list --max-count=10 ${targetSha}`]: {

452+

stdout: `${targetSha}\n`,

453+

},

454+

[`git -C ${tempDir} checkout --detach ${targetSha}`]: { stdout: "" },

455+

"pnpm --version": { stdout: "10.0.0" },

456+

"pnpm install": { stdout: "" },

457+

"pnpm build": { stdout: "" },

458+

"pnpm ui:build": { stdout: "" },

459+

[doctorCommand]: { stdout: "" },

460+

});

461+462+

const result = await runWithRunner(runner, {

463+

channel: "dev",

464+

devTargetRef: "refs/tags/v2026.5.19-beta.2",

465+

});

466+467+

expect(result.status).toBe("ok");

468+

expect(calls).toContain(`git -C ${tempDir} fetch --all --prune --no-tags`);

469+

expect(calls).not.toContain(`git -C ${tempDir} fetch --all --prune --tags`);

470+

expect(calls).toContain(

471+

`git -C ${tempDir} fetch origin +refs/tags/v2026.5.19-beta.2:refs/tags/v2026.5.19-beta.2`,

472+

);

473+

expect(calls).toContain(`git -C ${tempDir} rev-parse refs/tags/v2026.5.19-beta.2^{}`);

474+

});

475+476+

it("does not resolve stale local dev tag target refs after targeted tag fetch failure", async () => {

477+

await setupGitCheckout();

478+

const { runner, calls } = createRunner({

479+

...buildGitWorktreeProbeResponses(),

480+

[`git -C ${tempDir} fetch --all --prune --no-tags`]: { stdout: "" },

481+

[`git -C ${tempDir} remote`]: { stdout: "origin\n" },

482+

[`git -C ${tempDir} fetch origin +refs/tags/v2026.5.19-beta.2:refs/tags/v2026.5.19-beta.2`]: {

483+

code: 1,

484+

stderr: "would clobber existing tag",

485+

},

486+

});

487+488+

const result = await runWithRunner(runner, {

489+

channel: "dev",

490+

devTargetRef: "refs/tags/v2026.5.19-beta.2",

491+

});

492+493+

expect(result.status).toBe("error");

494+

expect(result.reason).toBe("no-target-sha");

495+

expect(calls).toContain(

496+

`git -C ${tempDir} fetch origin +refs/tags/v2026.5.19-beta.2:refs/tags/v2026.5.19-beta.2`,

497+

);

498+

expect(calls).not.toContain(`git -C ${tempDir} rev-parse refs/tags/v2026.5.19-beta.2^{}`);

499+

expect(calls).not.toContain(`git -C ${tempDir} rev-parse refs/tags/v2026.5.19-beta.2`);

500+

});

501+406502

it("aborts rebase on failure", async () => {

407503

await setupGitCheckout();

408504

const { runner, calls } = createRunner({

@@ -537,7 +633,7 @@ describe("runGatewayUpdate", () => {

537633

if (key === `git -C ${tempDir} rev-parse --abbrev-ref --symbolic-full-name @{upstream}`) {

538634

return { stdout: "origin/main", stderr: "", code: 0 };

539635

}

540-

if (key === `git -C ${tempDir} fetch --all --prune --tags`) {

636+

if (key === `git -C ${tempDir} fetch --all --prune --no-tags`) {

541637

return { stdout: "", stderr: "", code: 0 };

542638

}

543639

if (key === `git -C ${tempDir} rev-parse @{upstream}`) {

@@ -758,7 +854,7 @@ describe("runGatewayUpdate", () => {

758854

if (key === `git -C ${tempDir} rev-parse --abbrev-ref --symbolic-full-name @{upstream}`) {

759855

return { stdout: "origin/main", stderr: "", code: 0 };

760856

}

761-

if (key === `git -C ${tempDir} fetch --all --prune --tags`) {

857+

if (key === `git -C ${tempDir} fetch --all --prune --no-tags`) {

762858

return { stdout: "", stderr: "", code: 0 };

763859

}

764860

if (key === `git -C ${tempDir} rev-parse @{upstream}`) {

@@ -873,7 +969,7 @@ describe("runGatewayUpdate", () => {

873969

if (key === `git -C ${tempDir} rev-parse --abbrev-ref --symbolic-full-name @{upstream}`) {

874970

return { stdout: "origin/main", stderr: "", code: 0 };

875971

}

876-

if (key === `git -C ${tempDir} fetch --all --prune --tags`) {

972+

if (key === `git -C ${tempDir} fetch --all --prune --no-tags`) {

877973

return { stdout: "", stderr: "", code: 0 };

878974

}

879975

if (key === `git -C ${tempDir} rev-parse @{upstream}`) {

@@ -970,7 +1066,7 @@ describe("runGatewayUpdate", () => {

9701066

if (key === `git -C ${tempDir} rev-parse --abbrev-ref --symbolic-full-name @{upstream}`) {

9711067

return { stdout: "origin/main", stderr: "", code: 0 };

9721068

}

973-

if (key === `git -C ${tempDir} fetch --all --prune --tags`) {

1069+

if (key === `git -C ${tempDir} fetch --all --prune --no-tags`) {

9741070

return { stdout: "", stderr: "", code: 0 };

9751071

}

9761072

if (key === `git -C ${tempDir} rev-parse @{upstream}`) {

@@ -1084,7 +1180,7 @@ describe("runGatewayUpdate", () => {

10841180

if (key === `git -C ${tempDir} rev-parse --abbrev-ref --symbolic-full-name @{upstream}`) {

10851181

return { stdout: "origin/main", stderr: "", code: 0 };

10861182

}

1087-

if (key === `git -C ${tempDir} fetch --all --prune --tags`) {

1183+

if (key === `git -C ${tempDir} fetch --all --prune --no-tags`) {

10881184

return { stdout: "", stderr: "", code: 0 };

10891185

}

10901186

if (key === `git -C ${tempDir} rev-parse @{upstream}`) {

@@ -1182,7 +1278,7 @@ describe("runGatewayUpdate", () => {

11821278

if (key === `git -C ${tempDir} rev-parse --abbrev-ref --symbolic-full-name @{upstream}`) {

11831279

return { stdout: "origin/main", stderr: "", code: 0 };

11841280

}

1185-

if (key === `git -C ${tempDir} fetch --all --prune --tags`) {

1281+

if (key === `git -C ${tempDir} fetch --all --prune --no-tags`) {

11861282

return { stdout: "", stderr: "", code: 0 };

11871283

}

11881284

if (key === `git -C ${tempDir} rev-parse @{upstream}`) {

@@ -1275,7 +1371,7 @@ describe("runGatewayUpdate", () => {

12751371

if (key === `git -C ${tempDir} rev-parse --abbrev-ref --symbolic-full-name @{upstream}`) {

12761372

return { stdout: "origin/main", stderr: "", code: 0 };

12771373

}

1278-

if (key === `git -C ${tempDir} fetch --all --prune --tags`) {

1374+

if (key === `git -C ${tempDir} fetch --all --prune --no-tags`) {

12791375

return { stdout: "", stderr: "", code: 0 };

12801376

}

12811377

if (key === `git -C ${tempDir} rev-parse @{upstream}`) {

@@ -1367,7 +1463,7 @@ describe("runGatewayUpdate", () => {

13671463

if (key === `git -C ${tempDir} status --porcelain -- :!dist/control-ui/`) {

13681464

return { stdout: "", stderr: "", code: 0 };

13691465

}

1370-

if (key === `git -C ${tempDir} fetch --all --prune --tags`) {

1466+

if (key === `git -C ${tempDir} fetch --all --prune --no-tags`) {

13711467

return { stdout: "", stderr: "", code: 0 };

13721468

}

13731469

if (key === `git -C ${tempDir} rev-parse ${targetSha}`) {

@@ -1447,7 +1543,7 @@ describe("runGatewayUpdate", () => {

14471543

if (key === `git -C ${tempDir} status --porcelain -- :!dist/control-ui/`) {

14481544

return { stdout: "", stderr: "", code: 0 };

14491545

}

1450-

if (key === `git -C ${tempDir} fetch --all --prune --tags`) {

1546+

if (key === `git -C ${tempDir} fetch --all --prune --no-tags`) {

14511547

return { stdout: "", stderr: "", code: 0 };

14521548

}

14531549

if (key === `git -C ${tempDir} rev-parse refs/remotes/origin/main`) {

@@ -1530,7 +1626,7 @@ describe("runGatewayUpdate", () => {

15301626

if (key === `git -C ${gitRoot} status --porcelain -- :!dist/control-ui/`) {

15311627

return { stdout: "", stderr: "", code: 0 };

15321628

}

1533-

if (key === `git -C ${gitRoot} fetch --all --prune --tags`) {

1629+

if (key === `git -C ${gitRoot} fetch --all --prune --no-tags`) {

15341630

return { stdout: "", stderr: "", code: 0 };

15351631

}

15361632

if (key === `git -C ${gitRoot} rev-parse refs/remotes/origin/main`) {

@@ -1606,7 +1702,7 @@ describe("runGatewayUpdate", () => {

16061702

if (key === `git -C ${tempDir} rev-parse --abbrev-ref --symbolic-full-name @{upstream}`) {

16071703

return { stdout: "origin/main", stderr: "", code: 0 };

16081704

}

1609-

if (key === `git -C ${tempDir} fetch --all --prune --tags`) {

1705+

if (key === `git -C ${tempDir} fetch --all --prune --no-tags`) {

16101706

return { stdout: "", stderr: "", code: 0 };

16111707

}

16121708

if (key === `git -C ${tempDir} rev-parse @{upstream}`) {