[DESKTOP] Function Node throws HTTP errors

In my workflow I have a Function node that loops through all items passed in from the previous node (about 200K items). When looping through this, it processes the first 64K items quickly, but then throws this error:

Failed to load resource: net::ERR_INCOMPLETE_CHUNKED_ENCODING

Followed by loads of this:
GET http://localhost:5679/rest/push?sessionId=qdoxe45amg net::ERR_CONNECTION_REFUSED

I initially picked this up, when trying to use the Rename Keys node, which just never completed. I then replaced this with a Function node, so that I could log to console.

Any ideas?

Hey @go4cas,

I wonder if you have hit some kind of soft limit on the desktop app which is causing the web server on the backend to fall over… I did once see a web service get killed when multiple requests were sent because some local AV with real time scanning was trying to be helpful and thought it was unusual activity and killed it could be worth checking there as I know we don’t really set any limits so it is down to the machines ability to handle it a lot of the time.

Hey @jon … I think you may be onto something here. I have created a n8n Docker container, and ran the exact same workflow, and it completes with no issue.

1 Like

Hey @go4cas,

Did you do a check for local AV? That is where I would start as I have seen it too many times before, Depending on the OS one of the few times I used for Windows for something I found that defender was a real pain when trying to run processes that run for a long time or make a lot of network / file calls quickly.