Gmail reader not extracting all attachments

Hello,

im having some issues with extracting the attachments from e-mails. in some cases, it only extracts 1 attachment instead of all 3, while in other cases it seems to work just fine. sometime it even returns no attachments while an e-mail might clearly have attachment when looking at it in the gmail box.

flow 7 tests this with 2 e-mail containing the same information but one 1 resend my self and the other i received from a client, the picture shows the e-mail clearly containing attachment but the output does not reflect this:

image
image

GUMLOOP link: https://www.gumloop.com/pipeline?workbook_id=pwvtnKpk5S2XpBkkGMmpFz&tab=5&run_id=eCxkV9K6r3sGVwqVThsAr5

Hey @Donna! If you’re reporting an issue with a flow or an error in a run, please include the run link and make sure it’s shareable so we can take a look.

  1. Find your run link on the history page. Format: https://www.gumloop.com/pipeline?run_id={{your_run_id}}&workbook_id={{workbook_id}}

  2. Make it shareable by clicking “Share” → ‘Anyone with the link can view’ in the top-left corner of the flow screen.
    GIF guide

  3. Provide details about the issue—more context helps us troubleshoot faster.

You can find your run history here: https://www.gumloop.com/history

Hey Donna, thank you for the context.

In your run, it looks like you’re passing the Email Bodies output into the Ask AI node instead of the Attachment File Names output. That aside, there’s an important caveat here: if an email has multiple attachments, the attachment files output separates them with a comma.

For example:
eCxkV9K6r3sGVwqVThsAr5/jackfruitcurry.docx,eCxkV9K6r3sGVwqVThsAr5/Rendang van kippendijen.docx,eCxkV9K6r3sGVwqVThsAr5/spitskoolsalade.docx

As you can see, each file is separated by a comma.

You can use a Split Text node here to get a list of individual files and process them in a loop. Here’s an example setup: https://www.gumloop.com/pipeline?workbook_id=sPMkQovCUvtP7FNmkbPCCE&tab=5

Let me know if this makes sense and works for you :slightly_smiling_face:

Hi, thanks again for the help — but the issue still isn’t resolved.

Just to clarify: I’m aware that the attached_file_names field returns a comma-separated string, and I’m not parsing it incorrectly — that part is understood.

The real issue is inconsistent behavior from the Gmail Reader when handling attachments.

Here’s what I’ve observed after testing with multiple emails:

  • In some cases, emails containing both .docx files and a .jpg image correctly list all attachments in attached_file_names.
  • In other cases — with a nearly identical structure — only the .jpg file is extracted, and the .docx attachments are missing from the output, even though they are present in the email itself.

This makes the behavior unreliable, and it seems like something is going wrong with how the attachments are parsed.
Do you have any idea what might cause this? And is there any workaround or fix?

Oh I see, thank you for the context. I have not seen this before so this is strange. I can see from your screenshot above that the email with the subject Recepten dinsdag 20 mei has more than one attachment but only one is available as output from the node.

Is there any difference between this email and the email with the subject Recepten dinsdag 20/5/2025 where all attachments are pulled?

Also, would it be possible to forward these emails to wasay@gumloop.com to see if I can reproduce this? No worries if they’re sensitive.

I have forwarded you the e-mails, in my own research i found this being the only difference:

After comparing raw MIME content from working and failing emails, I noticed a key difference:

  • Working email: top-level multipart/mixed → all .docx attachments extracted correctly.
  • Failing email: top-level multipart/related with a nested multipart/mixed → only the inline image gets extracted, .docx attachments are missed.

It seems the Reader doesn’t traverse into nested multipart/mixed parts inside multipart/related.

is there any work around ?

@Donna – Appreciate you sharing the emails. I haven’t been able to reproduce this issue on my end and I don’t think its a workflow issue.

I’ll create a ticket to investigate this further and will keep you posted. Really sorry about the trouble here!

Hey @Donna – We identified the bug and have pushed a fix. It’ll be live to production this week, I’ll keep you posted. Appreciate the patience here.

1 Like

Awesome! Looking forward to it

Hey @Donna – This should be fixed now, could you please delete and re-add the Gmail Reader node and test again?