Issue with failed tasks - New retries have to be started from the original execution

I’m running into that error above. My workflow is:

  1. Browse the list of previously run workflows
  2. Look for ones that have failed
  3. Try to re-run the failed workflows.
  4. I get that error.

I’m just curious how you’re supposed to re-start a failed workflow. It doesn’t seem to work when I choose either option listed here:

image

If you did not make any changes to the workflow both behave 100% identical because the original workflow (the one at the time of execution) is the same as the one that is currently saved.

But if you made changes to the workflow because you, for example, found a bug and that is why it did error (and the changes are in the node that did error or in any after it) then you can use the currently saved workflow instead to execute. That makes it very simple to fix a bug in a workflow without having to reproduce the input data.

Does that help and make sense?

Thanks jan - that does make sense.

Do you know why it gives me the error message “New retries have to be started from the original execution” though? It doesn’t seem to even retry to run the workflow with the stored data.

That message should be displayed if the retry did fail.

The part “New retries have to be started from the original execution” is just supposed to remind people that retrying a retry is not possible. If they want to try again they would have to retry the original execution that did fail.

Hm would be strange if it would use the data. If you retry it should by default keep the data from all nodes before the one that did error and then simply keep on running from there.

Do currently not know of any bug. If there is one and you have a way to reproduce it please open an issue on Github that we can have a look and fix it.

The part “New retries have to be started from the original execution” is just supposed to remind people that retrying a retry is not possible. If they want to try again they would have to retry the original execution that did fail.

Ah that makes sense.

Hm would be strange if it would use the data. If you retry it should by default keep the data from all nodes before the one that did error and then simply keep on running from there.

Yeah its pretty strange. I’m wondering if there’s any more detailed error logs in the docker container as to why it fails. Its almost like it doesn’t even start. (fails immediately after clicking retry).

Here’s the only errors I’m seeing in the docker container - and it doesn’t happen when I am manually re-running the workflow unfortunately:

(node:6) UnhandledPromiseRejectionWarning: TypeError: Cannot read property 'type' of null
    at Workflow.runWebhookMethod (/usr/local/lib/node_modules/n8n/node_modules/n8n-workflow/dist/src/Workflow.js:450:56)
    at ActiveWebhooks.removeWorkflow (/usr/local/lib/node_modules/n8n/node_modules/n8n-core/dist/src/ActiveWebhooks.js:45:28)
    at runMicrotasks (<anonymous>)
    at processTicksAndRejections (internal/process/task_queues.js:93:5)
(node:6) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 19)

As with every execution you can see what went wrong by simply going into it, in case you save failed executions. So after the retry you should see that failed retry in the execution list. Or does nothing get added to the list?

Yep so nothing actually gets added. It does insert a new error line into the previous workflows, but when I click on the folder icon to view the result, it just shows an empty workflow. There are no nodes, and no results.

hm, that seems to be then the problem. Just wonder why it would do that. Right now not the slightest idea. Does it happen with all of your workflows that fail and you retry or just with one specific one?

Okay, I had a little more time to investigate. Looks like there is a recurring error in one of the steps. It does only occur in one specific workflow so I’ll have to investigate this:

1 Like

I think I have a reproducible problem to try:

  1. Create a workflow with a credential stored, like email
  2. Remove the credential from the store (this breaks the workflow)
  3. Try running it (it will fail in the email step)
  4. Repair the workflow by adding a new credential and re-configuring email to use the new credential
  5. Try to re-run the Error’ed out execution. It still tries to use the old workflow, I cannot get it to use the new one.

Edit:
So I guess the issue is that the functionality to re-run an execution with the newest version of the workflow isn’t working for some reason.

Thanks a lot. Saw you also opened a Github issue here:

Will check it out.

1 Like

Issue got fixed with [email protected]

Awesome! Thanks jan. n8n is awesome - I’m really enjoying the experience!

1 Like

Thanks a lot! That is really great to hear!