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

推荐订阅源

Martin Fowler
Martin Fowler
Blog — PlanetScale
Blog — PlanetScale
Vercel News
Vercel News
L
LangChain Blog
Google DeepMind News
Google DeepMind News
H
Hackread – Cybersecurity News, Data Breaches, AI and More
F
Fortinet All Blogs
The GitHub Blog
The GitHub Blog
Recent Announcements
Recent Announcements
D
DataBreaches.Net
云风的 BLOG
云风的 BLOG
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
A
About on SuperTechFans
博客园_首页
N
Netflix TechBlog - Medium
Y
Y Combinator Blog
Hugging Face - Blog
Hugging Face - Blog
Last Week in AI
Last Week in AI
酷 壳 – CoolShell
酷 壳 – CoolShell
B
Blog
Apple Machine Learning Research
Apple Machine Learning Research
罗磊的独立博客
美团技术团队
V
V2EX

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(minimax): use account oauth endpoints · openclaw/open...
MatthewSchle · 2026-06-01 · via Recent Commits to openclaw:main
Original file line numberDiff line numberDiff line change

@@ -29,6 +29,67 @@ describe("normalizeOAuthExpires", () => {

2929

});

3030
3131

describe("loginMiniMaxPortalOAuth", () => {

32+

it("uses MiniMax account OAuth endpoints directly for global and CN login", async () => {

33+

for (const [region, expectedHosts] of [

34+

[

35+

"global",

36+

[

37+

"https://account.minimax.io/oauth2/device/code",

38+

"https://account.minimax.io/oauth2/token",

39+

],

40+

],

41+

[

42+

"cn",

43+

[

44+

"https://account.minimaxi.com/oauth2/device/code",

45+

"https://account.minimaxi.com/oauth2/token",

46+

],

47+

],

48+

] as const) {

49+

const requestedUrls: string[] = [];

50+

const fetchMock = vi.fn(async (input: RequestInfo | URL, init?: RequestInit) => {

51+

requestedUrls.push(input instanceof Request ? input.url : String(input));

52+

const body =

53+

init?.body instanceof URLSearchParams

54+

? init.body

55+

: new URLSearchParams(typeof init?.body === "string" ? init.body : "");

56+

if (requestedUrls.length === 1) {

57+

return new Response(

58+

JSON.stringify({

59+

user_code: "CODE",

60+

verification_uri: "https://example.com/device",

61+

expired_in: Date.now() + 10_000,

62+

state: body.get("state"),

63+

}),

64+

{ status: 200, headers: { "Content-Type": "application/json" } },

65+

);

66+

}

67+

return new Response(

68+

JSON.stringify({

69+

status: "success",

70+

access_token: "access",

71+

refresh_token: "refresh",

72+

expired_in: 3600,

73+

}),

74+

{ status: 200, headers: { "Content-Type": "application/json" } },

75+

);

76+

});

77+

vi.stubGlobal("fetch", fetchMock);

78+
79+

await expect(

80+

loginMiniMaxPortalOAuth({

81+

region,

82+

openUrl: vi.fn(async () => undefined),

83+

note: vi.fn(async () => undefined),

84+

progress: { update: vi.fn(), stop: vi.fn() },

85+

}),

86+

).resolves.toMatchObject({ access: "access", refresh: "refresh" });

87+

expect(requestedUrls).toEqual(expectedHosts);

88+
89+

vi.unstubAllGlobals();

90+

}

91+

});

92+
3293

it("rejects Date-invalid authorization expiries before formatting instructions", async () => {

3394

const fetchMock = vi.fn(async (_input: RequestInfo | URL, init?: RequestInit) => {

3495

const body =