n8n icon indicating copy to clipboard operation
n8n copied to clipboard

IMAP Trigger Node Binary File Attachments Corrupted

Open darrengoldner opened this issue 9 months ago • 13 comments

Bug Description

Beginning around approximately commit 9f87cc2, all binary files retrieved from the IMAP trigger nodes in my workflow are overstated by approximately 2X.

To Reproduce

Create a new IMAP trigger node with credentials to any IMAP mailbox with file attachments. Test trigger with filter criteria that include a message with attachments. Compare binary data for attachment(s) vs expectactions

Expected behavior

Binary file attachments should be retrieved exactly as they are represented in the IMAP mailbox.

Operating System

Ubuntu 22.04.3 LTS

n8n Version

1.38.2

Node.js Version

18.18.0

Database

PostgreSQL

Execution mode

main (default)

darrengoldner avatar May 06 '24 15:05 darrengoldner

Hey @darrengoldner,

Are the files actually bigger and corrupted or do we just show a larger size in the UI?

Joffcom avatar May 08 '24 13:05 Joffcom

Bigger and corrupted

darrengoldner avatar May 08 '24 13:05 darrengoldner

@darrengoldner I have managed to reproduce and have created NODE-1344 as the internal ticket to fix this.

Joffcom avatar May 10 '24 11:05 Joffcom

would it be possible to merge this fix into the Latest release? It was in 1.41.1 and then we moved up to 1.42.1 on latest track. Or is there a timeline for one of the latter minor versions which have the patch to become the latest?

darrengoldner avatar May 30 '24 16:05 darrengoldner

this fix should already be in the latest release. are you still seeing this issue ?

netroy avatar May 30 '24 16:05 netroy

Yes. AFAICT the behavior returned in 1.42.1. It had been resolved in 1.41.1

darrengoldner avatar May 30 '24 16:05 darrengoldner

Same here. Still seeing this issue with 1.42.1 (but can not tell if it was solved with 1.41.1). In my case the problem is with .wav files (but did not test other files)

webkp avatar Jun 03 '24 09:06 webkp

That is very odd, The change from 1.41.1 should be in 1.42.1, I will give it a quick test now and see if it is still an issue on 1.44.0

Joffcom avatar Jun 03 '24 09:06 Joffcom

@darrengoldner in case you are using a more recent version of n8n now: do you still encounter the problem? I switched to a community imap-node to to circumvent the problem for the moment until the problem is solved but I would like to use again n8n's core node instead of external ones once it is all working well.

webkp avatar Jun 27 '24 13:06 webkp

I haven't managed to reproduce this issue. What IMAP server are you folks seeing the issue with?

netroy avatar Jun 27 '24 13:06 netroy

Did you try with 1.42.1 @netroy ? I'll see if I can do an update the next couple days and try again.

webkp avatar Jun 27 '24 13:06 webkp

I have only tried to reproduce this on the latest code. Can you please try one of the newer releases to see if the issue is fixed now? 🙏🏽

netroy avatar Jun 27 '24 14:06 netroy

I can confirm that (for me) it is working again after moving from 1.42.1 to 1.47.1

But as @darrengoldner said above: Looks like the fix was included in 1.41.1 got lost in 1.42.1 and was in introdruced again in 1.43.0 (which was odd for me too)

webkp avatar Jun 28 '24 09:06 webkp