-
-
Notifications
You must be signed in to change notification settings - Fork 69.5k
Slack: only first file attachment is processed when multiple files are sent in one message #11892
Copy link
Copy link
Closed
Labels
bugSomething isn't workingSomething isn't working
Description
Description
When a user sends multiple file attachments in a single Slack message, only the first file is processed and made available to the agent. All subsequent files are silently dropped.
Root Cause
In resolveSlackMedia() (loader), the function iterates through files but returns immediately after the first successful download:
async function resolveSlackMedia(params) {
const files = params.files ?? [];
for (const file of files) {
// ... fetch and save ...
return { // ← returns after first file
path: saved.path,
contentType: saved.contentType,
placeholder: label ? `[Slack file: ${label}]` : '[Slack file]'
};
}
return null;
}Expected Behavior
All files in the message should be resolved and passed to the agent as separate attachments/content parts (images as image blocks, documents as text/file references, etc.).
Current Workaround
Send one file per message.
Environment
- OpenClaw version: 2026.2.6-3 (also reproduced on 2026.2.3-1)
- Channel: Slack (socket mode)
- OS: macOS (Darwin arm64)
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working
Type
Fields
Give feedbackNo fields configured for issues without a type.