Why do I get a "Invalid instance id 0" error when I try to handle a MaxFileSizeExceededError?

So everything was working great, until my workflow hit a large email. Then it choked with a MaxFileSizeExceededError. I then added the suggested error ignore handler, and now when trying to run the flow I get “Invalid instance id 0”

How can I fix this?

Welcome to the Make community!

What happens if you delete the filter condition? Does the error still occur?

samliewrequest private consultation

Join the unofficial Make Discord server to chat with other makers!

1 Like

Hi, I have a very similar error. Except I have added the ‘Ignore’ after an OpenAI module that was failing (due to exceeding maximum tokens). It fails to run the scenario with or without the filter. Note that the failure is occurring when attempting to run the scenario – not mid way through the execution. It is as though the scenario will not ‘compile’…

Preparing scenario for running.
Requesting execution.
Invalid instance id ‘0’.




P.S. as soon as I delete the Ignore module, then it will run again (though, of course, the OpenAI module fails for the reason stated above).

OK, I think I’ve fixed it for my purposes. I removed the Ignore, and instead added a Resume (right click on the module, select Error Handling, then select Resume). I entered what the output values should be on failure, and this now works for me.

(I made the output value=FAIL so that the Router could handle it)


No if I delete the error handling filter condition everything is fine (on smaller emails) but when I hit a large email it fails. Which is why I added the error handling as it suggested.

Hi @DanielArmstrong ,

I hope I’m not butting into your conversation, but I think the problem could be happening because of something like this:

Let’s say Module 10 (e.g. Google Mail) returns a value (e.g. ID) to pass to Module 11. When Module 10 does not fail, everything runs fine, and Module 11 acts on the ID value. When Module 10 fails, then execution stops. However, when you put an Ignore in place then the failed Module 10 instance potentially does not exist, and therefore next step cannot refer to the ID in the Module. If you put a Resume in place instead of an Ignore (as I described above), then you can specify the missing value – e.g. on failure, you can make ID = -1, then you can filter on the ID to handle the error.

I might be wrong, but I would be interested to see if this works for you like it worked for me. Also, if you fix it another way, I am also interested.