Fix structured IPC envelope leakage

Normalize EJClaw structured send_message envelopes, preserve attachments, unwrap stored room payloads, and add regression tests.
This commit is contained in:
Eyejoker
2026-04-28 01:35:26 +09:00
committed by GitHub
parent 20e1a1e5e1
commit 8bb77ffaa3
11 changed files with 291 additions and 14 deletions

View File

@@ -14,6 +14,7 @@ export async function forwardAuthorizedIpcMessage(
text: string,
senderRole?: string,
runId?: string,
attachments?: import('./types.js').OutboundAttachment[],
) => Promise<void>,
injectInboundMessage?: (payload: {
chatJid: string;
@@ -79,7 +80,13 @@ export async function forwardAuthorizedIpcMessage(
};
}
await sendMessage(msg.chatJid, msg.text, msg.senderRole, msg.runId);
await sendMessage(
msg.chatJid,
msg.text,
msg.senderRole,
msg.runId,
msg.attachments,
);
return {
outcome: 'sent',
chatJid: msg.chatJid,