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

推荐订阅源

H
Help Net Security
T
ThreatConnect
SecWiki News
SecWiki News
F
Future of Privacy Forum
AWS News Blog
AWS News Blog
C
Cisco Blogs
A
Arctic Wolf
Vercel News
Vercel News
The GitHub Blog
The GitHub Blog
Scott Helme
Scott Helme
V
V2EX
博客园 - 叶小钗
阮一峰的网络日志
阮一峰的网络日志
K
Kaspersky official blog
G
Google Developers Blog
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
P
Privacy International News Feed
C
Cyber Attacks, Cyber Crime and Cyber Security
N
News | PayPal Newsroom
Schneier on Security
Schneier on Security
NISL@THU
NISL@THU
Microsoft Azure Blog
Microsoft Azure Blog
量子位
The Hacker News
The Hacker News
Stack Overflow Blog
Stack Overflow Blog
Security Latest
Security Latest
M
Microsoft Research Blog - Microsoft Research
Google Online Security Blog
Google Online Security Blog
博客园_首页
C
CXSECURITY Database RSS Feed - CXSecurity.com
I
InfoQ
Google DeepMind News
Google DeepMind News
Y
Y Combinator Blog
The Cloudflare Blog
Microsoft Security Blog
Microsoft Security Blog
Martin Fowler
Martin Fowler
Cisco Talos Blog
Cisco Talos Blog
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
T
Troy Hunt's Blog
F
Fox-IT International blog
S
Security @ Cisco Blogs
博客园 - 司徒正美
cs.CV updates on arXiv.org
cs.CV updates on arXiv.org
C
Comments on: Blog
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
L
LINUX DO - 最新话题
GbyAI
GbyAI
Project Zero
Project Zero
腾讯CDC
T
Tailwind CSS Blog

Recent Commits to openclaw:main

test(e2e): assert release upgrade installs candidate · openclaw/openclaw@41eef4a ci(release): serialize plugin prerelease extension batch · openclaw/openclaw@a46556a fix(scripts): add docker e2e scheduler help · openclaw/openclaw@81f62a6 test(codex): wait for diagnostic event locally · openclaw/openclaw@083377a test(e2e): assert release plugin uninstall removes files · openclaw/openclaw@4b03e07 test(telegram): use platform temp path in bot harness · openclaw/openclaw@16d137d fix(imessage): seed direct DM history (#86706) · openclaw/openclaw@3452382 test(codex): complete diagnostic turn explicitly · openclaw/openclaw@11b1b7c test(scripts): make run-vitest test Windows-safe · openclaw/openclaw@5c3fb1f test: restore auth regression coverage · openclaw/openclaw@c04c03f fix(test): reject missing explicit vitest files · openclaw/openclaw@505aca9 test(plugins): canonicalize plugin install assertion paths · openclaw/openclaw@5174d97 fix(diagnostics): track model stream progress (#86757) · openclaw/openclaw@23e9bc8 Preserve runtime external auth snapshots (#85558) · openclaw/openclaw@711e963 fix(test): prepare macos runner tmpdir · openclaw/openclaw@7db4b3d test(agents): stabilize yielded exec timeout test · openclaw/openclaw@c14c043 test: stabilize media fallback and background timeout tests · openclaw/openclaw@3bb4be2 fix(whatsapp): warn once when group inbound dropped for missing chann… chore(release): refresh plugin sdk api baseline · openclaw/openclaw@e752f9b test(whatsapp): stabilize media format expectations · openclaw/openclaw@c43ed9e test(qqbot): make OPENCLAW_HOME media test Windows-safe · openclaw/openclaw@1e9b6b7 fix(test): forward installer smoke controls test: align image fast path expectations · openclaw/openclaw@21aefb8 test: align pnpm cache workflow assertion · openclaw/openclaw@c4f0682 test: enforce per-test ci threshold · openclaw/openclaw@4118a32 ci(mantis): pass crabbox capacity regions · openclaw/openclaw@4fdf617 ci: disable pnpm action cache on Windows · openclaw/openclaw@bc3d6ba fix(agents): skip wildcard catalog metadata refs (#86524) fix(test): bootstrap macos script stdin test(codex): avoid app-server diagnostic notification race fix(embedded-runner): preserve provider errors on cleanup takeover (#… · openclaw/openclaw@7fbca96 fix(agents): handle preflight compaction no-op budgets (#86709) · openclaw/openclaw@bcde7b1 fix: make QQ Bot media paths respect `OPENCLAW_HOME` configuration (#… · openclaw/openclaw@0d23c3b fix(tooling): skip gauntlet declaration prebuild fix(control-ui): support raw edits from editable config (#86726) · openclaw/openclaw@c9d0464 revert: iMessage group media attachment command (#86734) · openclaw/openclaw@5a33378 fix(release): stabilize beta validation after rebase · openclaw/openclaw@609d70d fix(test): measure kitchen sink gateway children · openclaw/openclaw@4738d0a fix(whatsapp): restore ack emoji identity fallback (#86697) · openclaw/openclaw@34d862d fix(imessage): send group media via attachment command · openclaw/openclaw@f322732 fix(test): harden plugin gauntlet proof · openclaw/openclaw@eab8d29 fix(release): stabilize beta validation after main rebase · openclaw/openclaw@9301598 refactor: use Rastermill for image processing (#86621) perf(discord): use libopus-wasm for voice opus fix(build): pin synthetic auth runtime dist entry (#86714) · openclaw/openclaw@3d06594 fix(plugin-sdk): preserve string-const unions as flat enum for deepse… · openclaw/openclaw@fddca99 fix(perf): bound session transcript stat fanout · openclaw/openclaw@2e6ba44 fix(test): bound plugin gauntlet prebuilds · openclaw/openclaw@6984a82 perf: speed up usage cost lookups · openclaw/openclaw@743bce2 Add OpenTelemetry LLM content spans (#86191) · openclaw/openclaw@f824e15 chore: remove unused tracked assets · openclaw/openclaw@592f192 fix(release): accept optional Discord voice decoder · openclaw/openclaw@8f1f790 fix(perf): tolerate passing filtered release gates · openclaw/openclaw@c410658 fix(release): stabilize beta validation tests · openclaw/openclaw@e049105 fix(ui): refresh raw copy i18n baseline · openclaw/openclaw@010a79b fix(packaging): bound dist inventory filesystem scans fix(test): remove image tool timeout slack · openclaw/openclaw@669df88 fix(cron): accept opaque session target keys · openclaw/openclaw@c9364f0 fix: honor skill source install aliases (#84842) · openclaw/openclaw@24d58af fix(test): avoid message tool bundled channel loads · openclaw/openclaw@6421808 test(onboard): guard docker e2e resources · openclaw/openclaw@80aa6d7 chore: bump OpenClaw to 2026.5.26 · openclaw/openclaw@d00d0a2 fix: stabilize discord voice receive recovery · openclaw/openclaw@321f06a perf: reduce session and auth cache hotpath work (#86678) · openclaw/openclaw@ee51169 fix(qa): stream gateway gauntlet prebuild output fix(cli): route plugin packaging recovery hints · openclaw/openclaw@56633e4 perf(agents): reuse model manifest context · openclaw/openclaw@ea2496b fix(diagnostics): expose missing telemetry signals (#86682) · openclaw/openclaw@ef8619d perf: avoid extra session snapshot cloning · openclaw/openclaw@71e9eaa fix: avoid compaction checkpoint transcript copies (#86666) · openclaw/openclaw@c59635a fix: preserve code mode failure output test: avoid message tool discovery in send helper · openclaw/openclaw@1514cc8 fix(scripts): bound guard inventory file reads · openclaw/openclaw@6defcb0 fix(test): isolate kitchen sink rpc home env feat(signal): support reaction approvals (#85894) fix(scripts): bound source scan file reads · openclaw/openclaw@57748a6 test(ollama): support cloud api live smoke · openclaw/openclaw@2a6b4ed test: serialize agents tools vitest files · openclaw/openclaw@978a2d0 fix(auto-reply): use context-aware overflow reserve hints (#84399) · openclaw/openclaw@3a4f2b1 feat(gateway): forward OpenAI sampling params (#84094) · openclaw/openclaw@6c7b3f3 perf: cache model cost indexes · openclaw/openclaw@068924e fix: hide unsupported best effort message option · openclaw/openclaw@5dc7043 refactor: reuse realtime output activity in google meet (#86665) fix(test): harden bundled plugin install sweep · openclaw/openclaw@84929e4 fix: prefer source public artifacts in source checkouts · openclaw/openclaw@c87957d test: type child process spawn mock · openclaw/openclaw@65a2105 test(installer): cover rocky cli installs · openclaw/openclaw@fe33747 docs: update changelog for landed fixes · openclaw/openclaw@da831e2 fix: dampen repeated device-required probes · openclaw/openclaw@399c692 fix(ui): keep local file markdown links inert · openclaw/openclaw@fc2d2d5 fix(update): avoid duplicate plugin smoke failures · openclaw/openclaw@342bde2 fix(gateway): cap retained compaction checkpoint bytes · openclaw/openclaw@d7361ef fix: stabilize tests and reduce plugin memory churn · openclaw/openclaw@c1a026a perf: reduce runtime metadata hotpath churn · openclaw/openclaw@1d21224 refactor: share realtime output activity tracking (#86661) fix(memory-wiki): bound compile page reads (#86660) · openclaw/openclaw@acbdb8c test(qa-matrix): use larger media coverage jpeg fix(cli): reject unknown command help roots (#81083) (thanks @YB0y) · openclaw/openclaw@bec7d56 test: improve test profiling helpers · openclaw/openclaw@68ab48b perf: reduce fuzzy matching allocations · openclaw/openclaw@ec7ad3b
fix(imessage): send group media via attachment command (#86770) · openclaw/openclaw@17f7ef5
omarshahine · 2026-05-26 · via Recent Commits to openclaw:main

@@ -60,46 +60,45 @@ describe("sendMessageIMessage receipts", () => {

6060

expect(result.receipt.sentAt).toBeGreaterThan(0);

6161

});

626263-

it("attaches a media receipt after attachment resolution", async () => {

63+

it("sends explicit chat media-only payloads through send-attachment auto transport", async () => {

6464

const client = createClient({ message_id: 12345 });

65+

const runCliJson = vi

66+

.fn()

67+

.mockResolvedValueOnce({ messageId: "p:0/media-guid", transferGuid: "transfer-1" });

65686669

const result = await sendMessageIMessage("chat_guid:chat-1", "", {

6770

config: IMESSAGE_TEST_CFG,

6871

client,

6972

mediaUrl: "/tmp/image.png",

7073

resolveAttachmentImpl: async () => ({ path: "/tmp/image.png", contentType: "image/png" }),

74+

runCliJson,

7175

});

727673-

expect(result.messageId).toBe("12345");

77+

expect(result.messageId).toBe("p:0/media-guid");

7478

expect(result.sentText).toBe("");

7579

expect(result.echoText).toBe("<media:image>");

76-

expect(result.receipt.primaryPlatformMessageId).toBe("12345");

77-

expect(result.receipt.platformMessageIds).toEqual(["12345"]);

78-

expect(client.request).toHaveBeenCalledWith(

79-

"send",

80-

expect.objectContaining({

81-

chat_guid: "chat-1",

82-

file: "/tmp/image.png",

83-

text: "",

84-

}),

85-

expect.any(Object),

86-

);

80+

expect(result.receipt.primaryPlatformMessageId).toBe("p:0/media-guid");

81+

expect(result.receipt.platformMessageIds).toEqual(["p:0/media-guid"]);

82+

expect(client.request).not.toHaveBeenCalled();

83+

expect(runCliJson.mock.calls).toEqual([

84+

[["send-attachment", "--chat", "chat-1", "--file", "/tmp/image.png", "--transport", "auto"]],

85+

]);

8786

expect(result.receipt.raw).toEqual([

8887

{

8988

channel: "imessage",

90-

messageId: "12345",

89+

messageId: "p:0/media-guid",

9190

conversationId: "chat-1",

9291

meta: { targetKind: "chat_guid" },

9392

},

9493

]);

9594

expect(result.receipt.parts).toEqual([

9695

{

9796

index: 0,

98-

platformMessageId: "12345",

97+

platformMessageId: "p:0/media-guid",

9998

kind: "media",

10099

raw: {

101100

channel: "imessage",

102-

messageId: "12345",

101+

messageId: "p:0/media-guid",

103102

conversationId: "chat-1",

104103

meta: { targetKind: "chat_guid" },

105104

},

@@ -108,6 +107,133 @@ describe("sendMessageIMessage receipts", () => {

108107

expect(result.receipt.sentAt).toBeGreaterThan(0);

109108

});

110109110+

it("resolves chat_id media-only payloads before using send-attachment", async () => {

111+

const client = createClient({ message_id: 12345 });

112+

const runCliJson = vi

113+

.fn()

114+

.mockResolvedValueOnce({ guid: "any;+;group-guid" })

115+

.mockResolvedValueOnce({ messageId: "p:0/media-guid" });

116+117+

const result = await sendMessageIMessage("chat_id:42", "", {

118+

config: IMESSAGE_TEST_CFG,

119+

client,

120+

mediaUrl: "/tmp/image.png",

121+

resolveAttachmentImpl: async () => ({ path: "/tmp/image.png", contentType: "image/png" }),

122+

runCliJson,

123+

});

124+125+

expect(result.messageId).toBe("p:0/media-guid");

126+

expect(client.request).not.toHaveBeenCalled();

127+

expect(runCliJson.mock.calls).toEqual([

128+

[["group", "--chat-id", "42"]],

129+

[

130+

[

131+

"send-attachment",

132+

"--chat",

133+

"any;+;group-guid",

134+

"--file",

135+

"/tmp/image.png",

136+

"--transport",

137+

"auto",

138+

],

139+

],

140+

]);

141+

});

142+143+

it("falls back to the existing rpc send path when send-attachment is unavailable", async () => {

144+

const client = createClient({ message_id: 12345 });

145+

const runCliJson = vi.fn().mockRejectedValueOnce(new Error("unknown command send-attachment"));

146+147+

const result = await sendMessageIMessage("chat_guid:chat-1", "", {

148+

config: IMESSAGE_TEST_CFG,

149+

client,

150+

mediaUrl: "/tmp/image.png",

151+

resolveAttachmentImpl: async () => ({ path: "/tmp/image.png", contentType: "image/png" }),

152+

runCliJson,

153+

});

154+155+

expect(result.messageId).toBe("12345");

156+

expect(runCliJson.mock.calls).toEqual([

157+

[["send-attachment", "--chat", "chat-1", "--file", "/tmp/image.png", "--transport", "auto"]],

158+

]);

159+

expect(client.request).toHaveBeenCalledWith(

160+

"send",

161+

expect.objectContaining({

162+

chat_guid: "chat-1",

163+

file: "/tmp/image.png",

164+

text: "",

165+

}),

166+

expect.any(Object),

167+

);

168+

});

169+170+

it("falls back to the existing rpc send path when chat_id lookup is unavailable", async () => {

171+

const client = createClient({ message_id: 12345 });

172+

const runCliJson = vi.fn().mockRejectedValueOnce(new Error("private API bridge unavailable"));

173+174+

const result = await sendMessageIMessage("chat_id:42", "", {

175+

config: IMESSAGE_TEST_CFG,

176+

client,

177+

mediaUrl: "/tmp/image.png",

178+

resolveAttachmentImpl: async () => ({ path: "/tmp/image.png", contentType: "image/png" }),

179+

runCliJson,

180+

});

181+182+

expect(result.messageId).toBe("12345");

183+

expect(runCliJson.mock.calls).toEqual([[["group", "--chat-id", "42"]]]);

184+

expect(client.request).toHaveBeenCalledWith(

185+

"send",

186+

expect.objectContaining({

187+

chat_id: 42,

188+

file: "/tmp/image.png",

189+

text: "",

190+

}),

191+

expect.any(Object),

192+

);

193+

});

194+195+

it("rejects failed send-attachment json instead of reporting success", async () => {

196+

const client = createClient({ message_id: 12345 });

197+

const runCliJson = vi

198+

.fn()

199+

.mockResolvedValueOnce({ success: false, error: "attachment delivery failed" });

200+201+

await expect(

202+

sendMessageIMessage("chat_guid:chat-1", "", {

203+

config: IMESSAGE_TEST_CFG,

204+

client,

205+

mediaUrl: "/tmp/image.png",

206+

resolveAttachmentImpl: async () => ({ path: "/tmp/image.png", contentType: "image/png" }),

207+

runCliJson,

208+

}),

209+

).rejects.toThrow("attachment delivery failed");

210+

expect(client.request).not.toHaveBeenCalled();

211+

});

212+213+

it("keeps DM handle media sends on the existing rpc send path", async () => {

214+

const client = createClient({ message_id: 12345 });

215+

const runCliJson = vi.fn();

216+217+

await sendMessageIMessage("+15551234567", "", {

218+

config: IMESSAGE_TEST_CFG,

219+

client,

220+

mediaUrl: "/tmp/image.png",

221+

resolveAttachmentImpl: async () => ({ path: "/tmp/image.png", contentType: "image/png" }),

222+

runCliJson,

223+

});

224+225+

expect(runCliJson).not.toHaveBeenCalled();

226+

expect(client.request).toHaveBeenCalledWith(

227+

"send",

228+

expect.objectContaining({

229+

to: "+15551234567",

230+

file: "/tmp/image.png",

231+

text: "",

232+

}),

233+

expect.any(Object),

234+

);

235+

});

236+111237

it("preserves literal media placeholder text when no attachment is sent", async () => {

112238

const client = createClient({ guid: "p:0/imsg-text" });

113239